Reset caches on logout

This commit is contained in:
thePR0M3TH3AN committed 2026-01-29 15:54:44 -05:00
1 parent 3b3e7c757c
commit 1642b787ec
5 files changed
+44

No files matched your search

+16
View File
@@ -4706,6 +4706,22 @@ class Application {
}
}
if (typeof this.nostrService?.stopDirectMessageSubscription === "function") {
try {
this.nostrService.stopDirectMessageSubscription();
} catch (error) {
devLogger.warn("Failed to stop DM subscription during logout:", error);
}
}
if (typeof this.nostrService?.clearDirectMessages === "function") {
try {
this.nostrService.clearDirectMessages({ emit: true });
} catch (error) {
devLogger.warn("Failed to clear cached DMs during logout:", error);
}
}
if (typeof this.nostrService?.clearVideoSubscription === "function") {
try {
this.nostrService.clearVideoSubscription();