mirror of
https://github.com/kingomarnajjar/flex-template-web.git
synced 2026-07-26 06:47:17 +10:00
Use proper method for unsetting Sentry user context on logout
Current implementation causes an error popup on logout if Sentry is enabled. This is because `remove_user` is not a valid method on the `scope` object. Changing to use the `setUser` with a `null` parameter as discussed here - https://github.com/getsentry/sentry-docs/issues/500
This commit is contained in:
parent
313ab16451
commit
55bf312b87
1 changed files with 1 additions and 1 deletions
|
|
@ -43,7 +43,7 @@ export const setUserId = userId => {
|
|||
|
||||
export const clearUserId = () => {
|
||||
Sentry.configureScope(scope => {
|
||||
scope.remove_user();
|
||||
scope.setUser(null);
|
||||
});
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue