fix: clean up exports, add reset

This commit is contained in:
Mutasem Aldmour 2024-09-19 15:50:21 +02:00
parent a150c3d694
commit ba8df60304
No known key found for this signature in database
GPG key ID: 3DFA8122BB7FD6B8
2 changed files with 5 additions and 3 deletions

View file

@ -144,6 +144,10 @@ export class Telemetry {
}
}
reset() {
this.rudderStack?.reset();
}
flushPageEvents() {
const queue = this.pageEventQueue;
this.pageEventQueue = [];

View file

@ -140,6 +140,7 @@ export const useUsersStore = defineStore(STORES.USERS, () => {
const unsetCurrentUser = () => {
currentUserId.value = null;
currentUserCloudInfo.value = null;
telemetry.reset();
RBACStore.setGlobalScopes([]);
};
@ -374,11 +375,8 @@ export const useUsersStore = defineStore(STORES.USERS, () => {
globalRoleName,
personalizedNodeTypes,
addUsers,
setCurrentUser,
loginWithCookie,
initialize,
unsetCurrentUser,
deleteUserById,
setPersonalizationAnswers,
loginWithCreds,
logout,