diff --git a/common/content/editor.js b/common/content/editor.js index ca8fddc6..90a146cd 100644 --- a/common/content/editor.js +++ b/common/content/editor.js @@ -165,16 +165,13 @@ function Editor() //{{{ function (args) { let [lhs, rhs] = args; - if (rhs) + if (lhs.match(/\W/)) { - if (lhs.match(/\W/)) - { - liberator.echoerr("E474: Invalid argument"); - return false; - } - - editor.addAbbreviation(mode, lhs, rhs); + liberator.echoerr("E474: Invalid argument"); + return false; } + if (rhs) + editor.addAbbreviation(mode, lhs, rhs); else editor.listAbbreviations(mode, lhs || ""); },