[5.x] Avoid hardcoded nocache url in js#13199
Conversation
oops, first Statamic PR for me :)
They shouldn't have anyway. It was doing a I don't see how it would have ever hit |
The |
|
Gotcha, I thought you meant you had a Statamic multisite site configured at a subdirectory, not the entire app. |
This PR modifies the
/!/nocacheURL in the NoCache JavaScript to utilizeURL::prependSiteUrl(), thereby ensuring that it uses to the site’sAPP_URLconfiguration. This aligns with the behavior of other action routes, such as forms and authentication.Sites running on a subdirectory (e.g., https://domain.com/subsite) now have their NoCache AJAX requests sent to https://domain.com/!/nocache instead of https://domain.com/subsite/!/nocache.