From 0d5a392a11824cea4dc275348a6d3c5bae7ea7ec Mon Sep 17 00:00:00 2001 From: Adriaan Zonnenberg Date: Sun, 19 Feb 2017 22:10:05 +0100 Subject: [PATCH] Use `unlet!` instead of `unlet` A bang after unlet suppresses the error if there is no such variable, which removes the need for checking if the variable exists. --- syntax/vue.vim | 40 ++++++++++------------------------------ 1 file changed, 10 insertions(+), 30 deletions(-) diff --git a/syntax/vue.vim b/syntax/vue.vim index 9eb5a2f..1780d55 100644 --- a/syntax/vue.vim +++ b/syntax/vue.vim @@ -30,78 +30,58 @@ endif syntax include @HTML syntax/html.vim -if exists("b:current_syntax") - unlet b:current_syntax -endif +unlet! b:current_syntax syntax region html keepend start=/^