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

Helpscout - Allow users to accept invites #1133

Merged
merged 11 commits into from
Oct 14, 2024
Merged

Helpscout - Allow users to accept invites #1133

merged 11 commits into from
Oct 14, 2024

Conversation

caleballdrin
Copy link
Contributor

Description

https://secure.helpscout.net/conversation/2731091026/1241412?folderId=7669074

  • Accept account invites
  • Redirect old links

Checklist:

  • I have given my PR a title with the format "MPDX-(JIRA#) (summary sentence max 80 chars)"
  • I have applied the appropriate labels. (Add the label "On Staging" to get the branch automatically merged into staging.)
  • I have requested a review from another person on the project

@caleballdrin caleballdrin self-assigned this Oct 11, 2024
@caleballdrin caleballdrin requested review from canac and dr-bizz October 11, 2024 21:30
Copy link
Contributor

github-actions bot commented Oct 11, 2024

Bundle sizes [mpdx-react]

Compared against e1c3140

Route Size (gzipped) Diff
/acceptInvite 83.08 KB added
/account_lists/[accountListId]/accept_invite/[inviteId] 80.16 KB added
/organizations/[orgId]/accept_invite/[inviteId] 80.16 KB added

Copy link
Contributor

@dr-bizz dr-bizz left a comment

Choose a reason for hiding this comment

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

Looking great! I left a few comments, but that is it. Great work. I don't want to block you so I will approve this.

pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
Copy link
Contributor

@canac canac left a comment

Choose a reason for hiding this comment

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

Great work! I think the most important thing from my comments is removing useAccountListId() because unless I'm mistaken it will either always return undefined or might even be returning the inviter's account list id. It might be working because of the default account list redirect logic you implemented. But if we're relying on that, let's make it explicit and redirect the user to /accountLists/_/settings/preferences (with an underscore as an intentionally invalid account list id or some other clearly invalid id) and add a code comment to document what we're doing.

pages/acceptInvite.test.tsx Outdated Show resolved Hide resolved
pages/acceptInvite.test.tsx Show resolved Hide resolved
@canac
Copy link
Contributor

canac commented Oct 14, 2024

Also, old organization invite links don't redirect to the new URLs but that might be OK because they might not be as common.

pages/acceptInvite.page.tsx Outdated Show resolved Hide resolved
@caleballdrin caleballdrin merged commit 2b6212e into main Oct 14, 2024
18 checks passed
@caleballdrin caleballdrin deleted the invite-redirect branch October 14, 2024 17:07
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.

3 participants