fix: multiple push notifications susbscriptions on multiple account servers (#1069)

This commit is contained in:
Joaquín Sánchez 2023-01-13 13:54:30 +01:00 committed by GitHub
parent a733fbba08
commit 1d151c53c4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 33 additions and 7 deletions

View file

@ -24,3 +24,12 @@ export interface CustomEmojisInfo {
lastUpdate: number
emojis: mastodon.v1.CustomEmoji[]
}
export type PushSubscriptionErrorCode = 'too_many_registrations'
export class PushSubscriptionError extends Error {
code: PushSubscriptionErrorCode
constructor(code: PushSubscriptionErrorCode, message?: string) {
super(message)
this.code = code
}
}