-
Notifications
You must be signed in to change notification settings - Fork 309
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-3803 add prefix to client storage #3806
base: main
Are you sure you want to change the base?
Conversation
@dillonstreator is attempting to deploy a commit to the Medplum Team on Vercel. A member of the Team first needs to authorize it. |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
packages/core/src/storage.ts
Outdated
} | ||
|
||
clear(): void { | ||
this.storage.clear(); | ||
const keys = this.storage instanceof MemoryStorage ? this.storage.keys() : Object.keys(this.storage); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While Object.keys(this.storage)
works for localStorage, this is not safe for any Storage
implementation. Might need to create a new interface that extends Storage
and adds a keys
method.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
94daee9 is an attempt at solving this issue
…ements keys() method
Fixes #3803
Warning
This is a breaking change for any client that depends on the local storage key names
activeLogin
&logins
and as such should be highly visible in release notes.