<p></p>
<p><b>@gravitystorm</b> commented on this pull request.</p>
<hr>
<p>In <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3398#discussion_r803454775">app/controllers/application_controller.rb</a>:</p>
<pre style='color:#555'>> @@ -349,7 +349,7 @@ def deny_access(_exception)
elsif current_user
set_locale
respond_to do |format|
- format.html { redirect_to :controller => "errors", :action => "forbidden" }
+ format.html { redirect_to :controller => "/errors", :action => "forbidden" }
</pre>
<p dir="auto">The controller names are a bit more complex than it first appears! So if you are in a namespaced controller (e.g. <code>Account::DeletionsController</code>) then <code>redirect_to :controller => "errors"</code> means redirecting to <code>Account::ErrorsController</code>. I guess this makes some sense in some places but it's not what we want here. Using the forward slash is the equivalent of using the <code>::</code> prefix for ruby class names (e.g. ::File), so it makes sure the redirection is to <code>ErrorsController</code> regardless of any namespacing in the requesting controller.</p>
<p dir="auto">This is all irrelevant if we used named paths everywhere, but that's still a work in progress and we don't yet have named paths for the errors controller.</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3398#discussion_r803454775">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLM6IR4K7ENGRPCZZ5TU2N63BANCNFSM5KEFRLAQ">unsubscribe</a>.<br />Triage notifications on the go with GitHub Mobile for <a href="https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675">iOS</a> or <a href="https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub">Android</a>.
<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AAK2OLNIZR7GKAOSAP47UATU2N63BA5CNFSM5KEFRLA2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOGROWGBQ.gif" height="1" width="1" alt="" /><span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><openstreetmap/openstreetmap-website/pull/3398/review/878535430</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/3398#discussion_r803454775",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/3398#discussion_r803454775",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>