Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions lua/rest-nvim/utils/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,7 @@ end
-- file_exists checks if the provided file exists and returns a boolean
-- @param file File to check
M.file_exists = function(file)
file = io.open(file, "rb")
if file then
file:close()
end
return file ~= nil
return vim.fn.filereadable(file) == 1
end

-- read_file Reads all lines from a file and returns the content as a table
Expand Down