Skip to content

Fix edge cases with deleting last org/project #892

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

Merged
merged 6 commits into from
Feb 9, 2024

Conversation

matt-aitken
Copy link
Member

There were a few bugs with project/org deleting

  • The code that selects the best project to show if there's no cookie and the user lands on the root of the site wasn't factoring in deleted projects
  • If you delete your last project (across all orgs) an error was happening
  • If an org had any deleted projects (ever) it couldn't be deleted

You could create multiple orgs and projects with the same name by hitting entering twice on the new org page

@matt-aitken matt-aitken requested a review from ericallam February 8, 2024 18:23
Copy link

changeset-bot bot commented Feb 8, 2024

⚠️ No Changeset found

Latest commit: a2cc52e

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Comment on lines +379 to +382
<PopoverMenuItem
to={newProjectPath(organization)}
title="New project"
icon="plus"
Copy link
Member Author

Choose a reason for hiding this comment

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

If you delete the last project in an org and then navigate somehow to a different org you end up with an org you can't get to in the nav. This allows you to create a project for that org.

@matt-aitken matt-aitken merged commit 9ae0ca6 into main Feb 9, 2024
@matt-aitken matt-aitken deleted the delete-last-project-fix branch February 9, 2024 11:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant