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

fix: addAccountToGroup #6071

Merged
merged 2 commits into from
Jan 31, 2020
Merged

Conversation

kieckhafer
Copy link
Member

Impact: minor
Type: bugfix

Issue

accounts were only getting added to one group when creating an account, instead of being added to all groups they should have been added to. i.e. the initial user should be added to the accounts-manager and system-manager groups when created, but was only being added to accounts-manager and therefore no shop could be created.

Solution

Update the addAccountToGroup function to run synchronously as to not overwrite the other data being run at the same time.

Breaking changes

None

Testing

  1. Start a new app instance (clean database)
  2. create an initial user
  3. Create a shop. Doing this should prove the user is in both groups.
  4. Open a mongodb viewer and see your accounts.groups array has both groups.

Signed-off-by: Erik Kieckhafer <[email protected]>
Copy link
Contributor

@aldeed aldeed left a comment

Choose a reason for hiding this comment

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

Approve code only, didn't test

Copy link
Member

@manueldelreal manueldelreal left a comment

Choose a reason for hiding this comment

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

:shipit:

@kieckhafer kieckhafer merged commit 10760f7 into release-3.0.0 Jan 31, 2020
@kieckhafer kieckhafer deleted the fix-kieckhafer-addAccountToGroup branch January 31, 2020 23:58
@kieckhafer kieckhafer mentioned this pull request Feb 4, 2020
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