Skip to content

Commit

Permalink
🐛 Fix type error on err.message
Browse files Browse the repository at this point in the history
  • Loading branch information
lambdalisue committed Nov 7, 2024
1 parent b44927b commit 943a4d4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion denops/@denops-private/service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ class Plugin {
try {
return await this.#denops.dispatcher[fn](...args);
} catch (err) {
const errMsg = err.message ?? err;
const errMsg = err instanceof Error ? err.message : String(err);
throw new Error(
`Failed to call '${fn}' API in '${this.name}': ${errMsg}`,
);
Expand Down

0 comments on commit 943a4d4

Please sign in to comment.