Skip to content

Commit

Permalink
Fix dirs bug
Browse files Browse the repository at this point in the history
  • Loading branch information
tomodachi94 committed Dec 18, 2022
1 parent 05afb06 commit ee60761
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions unicorn/core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,10 @@ end
--- Creates folders from package_table.dirs
-- @param package_table A valid package table
local function action_make_folders(package_table)
for _, v in package_table.dirs do
fs.makeDir(v)
if package_table.dirs then
for _, v in pairs(package_table.dirs) do
fs.makeDir(v)
end
end
end

Expand Down Expand Up @@ -189,3 +191,4 @@ function unicorn.core.uninstall(package_name)
end

return unicorn.core

0 comments on commit ee60761

Please sign in to comment.