Skip to content

Commit

Permalink
Regression: Client crashing on startup (#22610)
Browse files Browse the repository at this point in the history
  • Loading branch information
gabriellsh committed Jul 7, 2021
1 parent 6dd2e35 commit fb78a1d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/authorization/client/startup.js
Expand Up @@ -13,7 +13,7 @@ Meteor.startup(() => {
CachedCollectionManager.onLogin(async () => {
const { roles } = await APIClient.v1.get('roles.list');
// if a role is checked before this collection is populated, it will return undefined
Roles._collection._docs._map = Object.fromEntries(roles.map((record) => [record._id, record]));
Roles._collection._docs._map = new Map(roles.map((record) => [record._id, record]));
Object.values(Roles._collection.queries).forEach((query) => Roles._collection._recomputeResults(query));

Roles.ready.set(true);
Expand Down

0 comments on commit fb78a1d

Please sign in to comment.