@@ -526,9 +526,9 @@ function! s:GistUpdate(content, gistid, gistnm, desc) abort
526
526
if res .status = ~# ' ^2'
527
527
let obj = webapi#json#decode (res .content)
528
528
let loc = obj[' html_url' ]
529
- redraw | echomsg ' Done: ' .loc
530
529
let b: gist = {" id" : a: gistid , " filename" : filename}
531
530
setlocal nomodified
531
+ redraw | echomsg ' Done: ' .loc
532
532
else
533
533
let loc = ' '
534
534
echohl ErrorMsg | echomsg ' Post failed: ' . res .message | echohl None
@@ -550,10 +550,10 @@ function! s:GistDelete(gistid) abort
550
550
\ " Content-Type" : " application/json" ,
551
551
\} , ' DELETE' )
552
552
if res .status = ~# ' ^2'
553
- redraw | echomsg ' Done: '
554
553
if exists (' b:gist' )
555
554
unlet b: gist
556
555
endif
556
+ redraw | echomsg ' Done: '
557
557
else
558
558
echohl ErrorMsg | echomsg ' Delete failed: ' . res .message | echohl None
559
559
endif
@@ -621,7 +621,6 @@ function! s:GistPost(content, private, desc, anonymous) abort
621
621
if res .status = ~# ' ^2'
622
622
let obj = webapi#json#decode (res .content)
623
623
let loc = obj[' html_url' ]
624
- redraw | echomsg ' Done: ' .loc
625
624
let b: gist = {
626
625
\ " filename" : filename,
627
626
\ " id" : matchstr (loc , ' [^/]\+$' ),
@@ -631,6 +630,7 @@ function! s:GistPost(content, private, desc, anonymous) abort
631
630
if s: update_GistID (b: gist [' id' ])
632
631
Gist - e
633
632
endif
633
+ redraw | echomsg ' Done: ' .loc
634
634
else
635
635
let loc = ' '
636
636
echohl ErrorMsg | echomsg ' Post failed: ' . res .message | echohl None
@@ -677,7 +677,6 @@ function! s:GistPostBuffers(private, desc, anonymous) abort
677
677
if res .status = ~# ' ^2'
678
678
let obj = webapi#json#decode (res .content)
679
679
let loc = obj[' html_url' ]
680
- redraw | echomsg ' Done: ' .loc
681
680
let b: gist = {
682
681
\ " filename" : filename,
683
682
\ " id" : matchstr (loc , ' [^/]\+$' ),
@@ -687,6 +686,7 @@ function! s:GistPostBuffers(private, desc, anonymous) abort
687
686
if s: update_GistID (b: gist [' id' ])
688
687
Gist - e
689
688
endif
689
+ redraw | echomsg ' Done: ' .loc
690
690
else
691
691
let loc = ' '
692
692
echohl ErrorMsg | echomsg ' Post failed: ' . res .message | echohl None
0 commit comments