Don't require user to type 'yes' to delete an empty directory
This commit is contained in:
parent
2e2b649232
commit
d2509d279e
@ -160,7 +160,7 @@ function! NERDTreeDeleteNode()
|
||||
let currentNode = g:NERDTreeFileNode.GetSelected()
|
||||
let confirmed = 0
|
||||
|
||||
if currentNode.path.isDirectory
|
||||
if currentNode.path.isDirectory && currentNode.getChildCount() > 0
|
||||
let choice =input("Delete the current node\n" .
|
||||
\ "==========================================================\n" .
|
||||
\ "STOP! To delete this entire directory, type 'yes'\n" .
|
||||
|
Loading…
Reference in New Issue
Block a user