Only reset auth status on successful auth

This commit is contained in:
Jonathan Staab
2023-09-18 11:40:45 -07:00
parent 47ddbf6498
commit 1d39da19f1
+4 -2
View File
@@ -102,10 +102,12 @@ export class ConnectionMeta {
this.pendingPublishes.set(event.id, {sent: Date.now(), event})
}
onReceiveOk(eventId: string) {
onReceiveOk(eventId: string, ok: boolean) {
const publish = this.pendingPublishes.get(eventId)
this.authStatus = AuthStatus.Ok
if (ok) {
this.authStatus = AuthStatus.Ok
}
if (publish) {
this.responseCount++