Skip to content
This repository was archived by the owner on Jul 6, 2022. It is now read-only.

feat: store user features#403

Merged
antsgar merged 3 commits intomasterfrom
feature/store-user-features
Sep 1, 2021
Merged

feat: store user features#403
antsgar merged 3 commits intomasterfrom
feature/store-user-features

Conversation

@antsgar
Copy link
Copy Markdown
Contributor

@antsgar antsgar commented Sep 1, 2021

Store user features fetched from /features endpoint.

this.roles =
(await this.storageService.getValue(StorageKey.UserRoles)) || [];
this.features =
(await this.storageService.getValue(StorageKey.UserFeatures)) || [];
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I believe getValue has a defaultValue param, if it makes things easier.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Good catch, I've updated it 🙂

@antsgar antsgar merged commit 9dde72f into master Sep 1, 2021
@antsgar antsgar deleted the feature/store-user-features branch September 1, 2021 18:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants