Age | Commit message (Collapse) | Author |
|
On a failed login the warden failure app gets called.
Some of the params are changed accordingly but controller
and action remain.
set_locale would detect there was no locale in the path
and thus attempt to redirect. However the params still
belong to the previous request which was a POST to
Api::SessionsController.
This route does not respond to get requests and so it
would trigger a 404 in production and a 500 in development.
This commit prevents set_locale to act upon warden failure
app controller calls by adding /new to the list of
`NON_LOCALE_PATHS`. (The path is updated by warden to the
name of the action called in the failure app).
A test is included in this commit that tries to login
with an invalid username, password combination and a german
locale set.
fixes #8805
|
|
our special error handler for json requests would turn all exceptions
into 500s - removed it. now the rescue_responses can do their thing
again.
|
|
If you inherit respond to and call it again in your controller
it will not overwrite the previous but add to it.
Since we always have some exceptions from the rules it's probably
easiest to be explicit in the controllers that require it themselves.
|
|
It used to run the action and then trigger a 500 because the
template was not found.
fixes !3 .
|
|
CouchRest > 1.2 does not use RestClient anymore. So we should not try to
catch its errors.
|
|
general.
|
|
|
|
|
|
|
|
|
|
* set locale based on request header
* enforce locale path prefix when current locale is not the default
* note: don't use root_path anymore, instead use home_path
|
|
|
|
Normally rails sends an html page which can't be parsed by the client.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
we're merging repositories into one
|