(rawReplies: Array<unknown>)
| 60 | } |
| 61 | |
| 62 | transformReplies(rawReplies: Array<unknown>): Array<unknown> { |
| 63 | const errorIndexes: Array<number> = [], |
| 64 | replies = rawReplies.map((reply, i) => { |
| 65 | if (reply instanceof ErrorReply) { |
| 66 | errorIndexes.push(i); |
| 67 | return reply; |
| 68 | } |
| 69 | |
| 70 | const { transformReply, args } = this.queue[i]; |
| 71 | return transformReply ? transformReply(reply, args.preserve, this.typeMapping) : reply; |
| 72 | }); |
| 73 | |
| 74 | if (errorIndexes.length) throw new MultiErrorReply(replies, errorIndexes); |
| 75 | return replies; |
| 76 | } |
| 77 | } |
no test coverage detected