Fixed fail new file save :w
This commit is contained in:
parent
a59a6f9364
commit
93a56c75ce
2 changed files with 2 additions and 6 deletions
|
|
@ -222,11 +222,7 @@ class Ex
|
|||
if not saved and fullPath?
|
||||
if not force and fs.existsSync(fullPath)
|
||||
throw new CommandError("File exists (add ! to override)")
|
||||
if saveas
|
||||
editor = atom.workspace.getActiveTextEditor()
|
||||
trySave(-> editor.saveAs(fullPath, editor)).then(deferred.resolve)
|
||||
else
|
||||
trySave(-> saveAs(fullPath, editor)).then(deferred.resolve)
|
||||
trySave(-> editor.saveAs(fullPath, editor)).then(deferred.resolve)
|
||||
|
||||
deferred.promise
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue