Skip to content
This repository was archived by the owner on Aug 12, 2025. It is now read-only.
Open
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
13 changes: 8 additions & 5 deletions templates/love/rocks/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,15 @@ local function get_os()
end
end

local function file_exists(name)
if love.filesystem.getInfo then -- >= 11
return love.filesystem.getInfo(name, 'file') ~= nil
else -- < 11
return love.filesystem.isFile(name)
local file_exists

if love.filesystem.getInfo then -- >= 11
local temp = {}
file_exists = function (name)
return love.filesystem.getInfo(name, 'file', temp) ~= nil
end
else -- < 11
file_exists = love.filesystem.isFile
end

local function path_exists(name)
Expand Down