Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent invalid slugs from causing redirects in org settings #2004

Merged
merged 2 commits into from
Aug 8, 2024

Conversation

emma-sg
Copy link
Member

@emma-sg emma-sg commented Aug 7, 2024

Also improves the slug editing experience by partially-slugifying the value as it's entered.

Previously, submitting a org slug value of ".." or similar would cause the frontend to redirect to a "page not found" page, with all accessible links leading to only /account/settings. This also causes the backend to reset the org slug to one generated from the org name on a reload.

@emma-sg emma-sg added the bug Something isn't working label Aug 7, 2024
@emma-sg emma-sg requested a review from ikreymer August 7, 2024 23:12
@emma-sg emma-sg self-assigned this Aug 7, 2024
Copy link
Member

@SuaYoo SuaYoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch!

frontend/src/pages/org/settings/settings.ts Outdated Show resolved Hide resolved
Co-authored-by: sua yoo <[email protected]>
@SuaYoo SuaYoo self-requested a review August 8, 2024 00:51
@ikreymer ikreymer merged commit 2b5f964 into main Aug 8, 2024
2 checks passed
@ikreymer ikreymer deleted the frontend-org-slug-validation branch August 8, 2024 21:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants