0
0
mirror of https://github.com/signalapp/libsignal.git synced 2024-09-19 19:42:19 +02:00

Remove circular node Native/Error dependency

This commit is contained in:
Alex Konradi 2024-09-11 14:49:31 -04:00 committed by GitHub
parent 7e078a2ed3
commit b705532230
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 10 additions and 8 deletions

7
node/Native.d.ts vendored
View File

@ -3,8 +3,6 @@
// SPDX-License-Identifier: AGPL-3.0-only
//
import { LibSignalError } from './ts/Errors';
// WARNING: this file was automatically generated
type Uuid = Buffer;
@ -122,7 +120,10 @@ export abstract class ChatListener {
ack: ServerMessageAck
): void;
_queue_empty(): void;
_connection_interrupted(reason: LibSignalError | null): void;
_connection_interrupted(
// A LibSignalError or null, but not naming the type to avoid circular import dependencies.
reason: Error | null
): void;
}
export abstract class MakeChatListener extends ChatListener {}

View File

@ -252,8 +252,8 @@ export class AuthenticatedChatService implements ChatService {
_queue_empty(): void {
listener.onQueueEmpty();
},
_connection_interrupted(cause: LibSignalError | null): void {
listener.onConnectionInterrupted(cause);
_connection_interrupted(cause: Error | null): void {
listener.onConnectionInterrupted(cause as LibSignalError | null);
},
};
Native.ChatService_SetListenerAuth(

View File

@ -3,8 +3,6 @@
// SPDX-License-Identifier: AGPL-3.0-only
//
import { LibSignalError } from './ts/Errors';
// WARNING: this file was automatically generated
type Uuid = Buffer;
@ -122,7 +120,10 @@ export abstract class ChatListener {
ack: ServerMessageAck
): void;
_queue_empty(): void;
_connection_interrupted(reason: LibSignalError | null): void;
_connection_interrupted(
// A LibSignalError or null, but not naming the type to avoid circular import dependencies.
reason: Error | null
): void;
}
export abstract class MakeChatListener extends ChatListener {}