Skip to content

Commit

Permalink
datafile.path: Include filenames in error messages
Browse files Browse the repository at this point in the history
Closes #17.
  • Loading branch information
hishamhm committed Jun 5, 2018
1 parent b477655 commit be9319d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions datafile.lua
Expand Up @@ -55,12 +55,12 @@ local function find_file(file, mode)
if code == 13 then
-- Permission denied, but it exists
if mode:match("w") then
return nil, err
return nil, file .. ": " .. err
else
return true, file
end
end
return nil, err
return nil, file .. ": " .. err
end
return true, file
end
Expand Down

0 comments on commit be9319d

Please sign in to comment.