File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -320,7 +320,7 @@ return {
320
320
-- Check if the buffer is valid and loaded
321
321
if vim .api .nvim_buf_is_valid (buf ) and vim .api .nvim_buf_is_loaded (buf ) then
322
322
local path = vim .api .nvim_buf_get_name (buf )
323
- if vim .fn .filereadable (path ) == 1 then supported = supported + 1 end
323
+ if vim .fn .filereadable (path ) ~= 0 then supported = supported + 1 end
324
324
end
325
325
end
326
326
@@ -345,7 +345,7 @@ Another possibility is to only save the session if there are at least two window
345
345
for _ , window in ipairs (windows ) do
346
346
local buffer = vim .api .nvim_win_get_buf (window )
347
347
local file_name = vim .api .nvim_buf_get_name (buffer )
348
- if vim .fn .filereadable (file_name ) then supported = supported + 1 end
348
+ if vim .fn .filereadable (file_name ) ~= 0 then supported = supported + 1 end
349
349
end
350
350
end
351
351
You can’t perform that action at this time.
0 commit comments