Skip to content

Commit

Permalink
Fix type error
Browse files Browse the repository at this point in the history
  • Loading branch information
Shougo committed Oct 17, 2023
1 parent 0326c2f commit 7fd2a51
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion denops/dpp/dpp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -591,7 +591,10 @@ function initPlugin(plugin: Plugin, basePath: string): Plugin {
for (
const key of Object.keys(plugin).filter((key) => key.startsWith("hook_"))
) {
hooks[key] = hooks[key].replaceAll(/\n\s*\\/g, "");
hooks[key] = (plugin[key as keyof typeof plugin] as string).replaceAll(
/\n\s*\\/g,
"",
);
}
plugin = Object.assign(plugin, hooks);

Expand Down

0 comments on commit 7fd2a51

Please sign in to comment.