Skip to content

Commit 673b6e6

Browse files
committed
Return original handler response after dispatch
This special "2" value is lost otherwise.
1 parent be29e76 commit 673b6e6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

autoload/dispatch.vim

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -274,10 +274,10 @@ function! s:dispatch(request) abort
274274
for handler in g:dispatch_handlers
275275
let response = call('dispatch#'.handler.'#handle', [a:request])
276276
if !empty(response)
277-
redraw
278277
let a:request.handler = handler
278+
redraw
279279
echo ':!'.a:request.expanded s:postfix(a:request)
280-
return 1
280+
return response
281281
endif
282282
endfor
283283
return 0

0 commit comments

Comments
 (0)