提交 73a68c84 编写于 作者: B Benjamin Pasero

ipc - add channel name to channel error

上级 0ac3c44c
......@@ -310,7 +310,7 @@ export class ChannelServer<TContext = string> implements IChannelServer<TContext
private onPromise(request: IRawPromiseRequest): void {
const channel = this.channels.get(request.channelName);
if (!channel) {
throw new Error('Unknown channel');
throw new Error(`Unknown channel: ${request.channelName}`);
}
const cancellationTokenSource = new CancellationTokenSource();
let promise: Promise<any>;
......@@ -349,7 +349,7 @@ export class ChannelServer<TContext = string> implements IChannelServer<TContext
private onEventListen(request: IRawEventListenRequest): void {
const channel = this.channels.get(request.channelName);
if (!channel) {
throw new Error('Unknown channel');
throw new Error(`Unknown channel: ${request.channelName}`);
}
const id = request.id;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册