fix: do not open exec open file if there is no active buffer

This commit is contained in:
Ali Almohaya 2022-09-27 00:21:42 +03:00
parent 60015c1736
commit ddc84cf0fd
No known key found for this signature in database
GPG key ID: 4B80BC43FC6007E0

View file

@ -27,7 +27,8 @@ function M.openFile()
local file_path = utils.get_current_relative_file_path()
if file_path:len() == 0 then
-- if there is no buffer opened
if file_path == "/" then
print("There is no active file to open!")
return
end