JSON: added clarification for non-supported Accept header formats
This commit is contained in:
parent
03ca0b2c69
commit
b556b054d1
2 changed files with 11 additions and 1 deletions
|
@ -45,6 +45,10 @@ class ApiController < ApplicationController
|
|||
request.format = "xml"
|
||||
break
|
||||
end
|
||||
|
||||
# In case the client requests some other format besides XML, JSON and */*,
|
||||
# we deliberately don't set request.format. The framework will return an
|
||||
# ActionController::UnknownFormat error to the client later on in this case.
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue