File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -6,9 +6,9 @@ export const main: Entrypoint = (denops) => {
6
6
test : async ( ...args ) => {
7
7
await delay ( 100 ) ;
8
8
await denops . cmd (
9
- `execute ' doautocmd <nomodeline> User' fnameescape(' DummyDispatcherPlugin:TestCalled:${
10
- JSON . stringify ( args )
11
- } ') `,
9
+ `doautocmd <nomodeline> User DummyDispatcherPlugin:TestCalled:${
10
+ JSON . stringify ( args ) . replaceAll ( / [ \\ " ] / g , "\\$&" )
11
+ } `,
12
12
) ;
13
13
return { result : "OK" , args } ;
14
14
} ,
Original file line number Diff line number Diff line change @@ -7,7 +7,9 @@ export const main: Entrypoint = (denops) => {
7
7
signal ?. addEventListener ( "abort" , async ( ) => {
8
8
await delay ( 100 ) ;
9
9
await denops . cmd (
10
- `doautocmd <nomodeline> User DummyInterruptPlugin:Interrupted:${ signal . reason } ` ,
10
+ `doautocmd <nomodeline> User DummyInterruptPlugin:Interrupted:${
11
+ String ( signal . reason ) . replaceAll ( / [ \\ " ] / g, "\\$&" )
12
+ } `,
11
13
) ;
12
14
} , { once : true } ) ;
13
15
}
You can’t perform that action at this time.
0 commit comments