You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-07 13:22:56 +03:00
convert "resp types" to interfaces to allow circular references
This commit is contained in:
@@ -1,67 +1,67 @@
|
||||
export class AbortError extends Error {
|
||||
constructor() {
|
||||
super('The command was aborted');
|
||||
}
|
||||
constructor() {
|
||||
super('The command was aborted');
|
||||
}
|
||||
}
|
||||
|
||||
export class WatchError extends Error {
|
||||
constructor() {
|
||||
super('One (or more) of the watched keys has been changed');
|
||||
}
|
||||
constructor() {
|
||||
super('One (or more) of the watched keys has been changed');
|
||||
}
|
||||
}
|
||||
|
||||
export class ConnectionTimeoutError extends Error {
|
||||
constructor() {
|
||||
super('Connection timeout');
|
||||
}
|
||||
constructor() {
|
||||
super('Connection timeout');
|
||||
}
|
||||
}
|
||||
|
||||
export class ClientClosedError extends Error {
|
||||
constructor() {
|
||||
super('The client is closed');
|
||||
}
|
||||
constructor() {
|
||||
super('The client is closed');
|
||||
}
|
||||
}
|
||||
|
||||
export class ClientOfflineError extends Error {
|
||||
constructor() {
|
||||
super('The client is offline');
|
||||
}
|
||||
constructor() {
|
||||
super('The client is offline');
|
||||
}
|
||||
}
|
||||
|
||||
export class DisconnectsClientError extends Error {
|
||||
constructor() {
|
||||
super('Disconnects client');
|
||||
}
|
||||
constructor() {
|
||||
super('Disconnects client');
|
||||
}
|
||||
}
|
||||
|
||||
export class SocketClosedUnexpectedlyError extends Error {
|
||||
constructor() {
|
||||
super('Socket closed unexpectedly');
|
||||
}
|
||||
constructor() {
|
||||
super('Socket closed unexpectedly');
|
||||
}
|
||||
}
|
||||
|
||||
export class RootNodesUnavailableError extends Error {
|
||||
constructor() {
|
||||
super('All the root nodes are unavailable');
|
||||
}
|
||||
constructor() {
|
||||
super('All the root nodes are unavailable');
|
||||
}
|
||||
}
|
||||
|
||||
export class ReconnectStrategyError extends Error {
|
||||
originalError: Error;
|
||||
socketError: unknown;
|
||||
originalError: Error;
|
||||
socketError: unknown;
|
||||
|
||||
constructor(originalError: Error, socketError: unknown) {
|
||||
super(originalError.message);
|
||||
this.originalError = originalError;
|
||||
this.socketError = socketError;
|
||||
}
|
||||
constructor(originalError: Error, socketError: unknown) {
|
||||
super(originalError.message);
|
||||
this.originalError = originalError;
|
||||
this.socketError = socketError;
|
||||
}
|
||||
}
|
||||
|
||||
export class ErrorReply extends Error {
|
||||
constructor(message: string) {
|
||||
super(message);
|
||||
this.stack = undefined;
|
||||
}
|
||||
constructor(message: string) {
|
||||
super(message);
|
||||
this.stack = undefined;
|
||||
}
|
||||
}
|
||||
|
||||
export class SimpleError extends ErrorReply {}
|
||||
|
Reference in New Issue
Block a user