diff options
author | Matthew Somerville <matthew-github@dracos.co.uk> | 2015-09-22 18:08:34 +0100 |
---|---|---|
committer | Matthew Somerville <matthew-github@dracos.co.uk> | 2015-09-22 18:08:34 +0100 |
commit | c26d57f1df8efc0cca43cfe287ae18809186dc74 (patch) | |
tree | e8c9b0786a35956e7c8cf0d3e47534f05d4fa2ee /perllib | |
parent | ece4b9dc4299b8f166da098d75899ded1ab7152a (diff) | |
parent | 441052eb05a759bc810dfbd9b7cb19c2747e44d6 (diff) |
Merge remote-tracking branch 'mysociety/1077-recursive-path'
Diffstat (limited to 'perllib')
-rw-r--r-- | perllib/Catalyst/Plugin/Session/State/Cookie.pm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/perllib/Catalyst/Plugin/Session/State/Cookie.pm b/perllib/Catalyst/Plugin/Session/State/Cookie.pm index e0a651ed9..bef0c1e66 100644 --- a/perllib/Catalyst/Plugin/Session/State/Cookie.pm +++ b/perllib/Catalyst/Plugin/Session/State/Cookie.pm @@ -50,6 +50,9 @@ sub update_session_cookie { sub cookie_is_rejecting { my ( $c, $cookie ) = @_; + # Prevent infinite loop in request->path. mySociety addition + return 0 if $c->request->has_uri && !$c->request->_has_path; + # Don't output cookie for JS or JPEG files. mySociety addition return 1 if substr($c->request->path, -3) eq '.js' || substr($c->request->path, -5) eq '.jpeg'; |