You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you set admin route as "/" and enable localization, once you create a document in one locale and try to copy to another locale, it will redirect to http://collections/{sampleCollectionSlug}/{documentID}?locale={toLocale}, which doesn't work because it does not include the serverURL.
Here is my PR #12560, it uses payload's formatAdminURL helper function to form the redirect URL appropriately.
anyuj
changed the title
"Copy to locale" redirect falsely when admin route is "/"
"Copy to locale" redirect incorrectly when admin route is "/"
May 26, 2025
Uh oh!
There was an error while loading. Please reload this page.
Describe the Bug
When you set admin route as "/" and enable localization, once you create a document in one locale and try to copy to another locale, it will redirect to
http://collections/{sampleCollectionSlug}/{documentID}?locale={toLocale}
, which doesn't work because it does not include the serverURL.Here is my PR #12560, it uses payload's
formatAdminURL
helper function to form the redirect URL appropriately.Link to the code that reproduces this issue
https://github.com/anyuj/wrong-redirect-route-for-copy-locale
Reproduction Steps
Use above repo or:
routes:{ admin:`/` }
Which area(s) are affected? (Select all that apply)
area: core
Environment Info
The text was updated successfully, but these errors were encountered: