Repository navigation
fix(web): handle duplicate organization URL update errors gracefully - #2808
Conversation
|
@anish1204 is attempting to deploy a commit to the Documenso Team Team on Vercel. A member of the Team first needs to authorize it. |
|
Important Review skippedAuto reviews are limited based on label configuration. 🏷️ Required labels (at least one) (1)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
|
@dguyen could you look into this PR i have explored a bug and fixed it accordingly. |
Description
In the Organisation section when we upate the url (which is like the UUID/slug) for the organisation if we try to fill the value with any other organisation url then we get an error as below
Issue here is in frontend there is already a exception handling present if the value entered is already present then show that error however it could not get that error as from backend the error code coming is 500.
Also in the update-organisation there is this particular an edge case missing.
Changes Made
Mapped duplicate organisation URL errors to AppErrorCode.ALREADY_EXISTS.
Improved error handling consistency between frontend and backend.
Testing Performed
Tested updating an organisation URL to an already existing URL.
Verified that the frontend now shows the correct validation error message instead of an unhandled error.
Tested updating an organisation with a unique URL and confirmed successful updates still work correctly.
After Fix

Checklist