MCPcopy
hub / github.com/redis/ioredis / returnError

Method returnError

lib/DataHandler.ts:72–89  ·  view source on GitHub ↗
(err: Error)

Source from the content-addressed store, hash-verified

70 }
71
72 private returnError(err: Error) {
73 const item = this.shiftCommand(err);
74 if (!item) {
75 return;
76 }
77
78 (err as any).command = {
79 name: item.command.name,
80 args: item.command.args,
81 };
82
83 if (item.command.name == "ssubscribe" && err.message.includes("MOVED")) {
84 this.redis.emit("moved");
85 return;
86 }
87
88 this.redis.handleReconnection(err, item);
89 }
90
91 private returnReply(reply: ReplyData) {
92 if (this.handleMonitorReply(reply)) {

Callers 1

constructorMethod · 0.95

Calls 2

shiftCommandMethod · 0.95
handleReconnectionMethod · 0.65

Tested by

no test coverage detected