diff options
author | Hisham Muhammad <hisham@gobolinux.org> | 2017-10-04 11:52:25 -0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2017-10-04 11:53:07 -0300 |
commit | e3a25e1c98fac6f52fe5e0653acea73d528a9a7b (patch) | |
tree | 9909877b1b0b79929d057e3a260f8309da998b39 | |
parent | 84b4fe99cac37850a97858e0b641043bd3178d8a (diff) | |
download | luarocks-e3a25e1c98fac6f52fe5e0653acea73d528a9a7b.tar.gz luarocks-e3a25e1c98fac6f52fe5e0653acea73d528a9a7b.tar.bz2 luarocks-e3a25e1c98fac6f52fe5e0653acea73d528a9a7b.zip |
Fix: handle missing dependencies section in manifest.
Closes #718.
-rw-r--r-- | src/luarocks/cmd/show.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/luarocks/cmd/show.lua b/src/luarocks/cmd/show.lua index 16c8d34e..21c75cf2 100644 --- a/src/luarocks/cmd/show.lua +++ b/src/luarocks/cmd/show.lua | |||
@@ -104,7 +104,7 @@ function show.command(flags, name, version) | |||
104 | elseif flags["issues"] then util.printout(descript.issues_url) | 104 | elseif flags["issues"] then util.printout(descript.issues_url) |
105 | elseif flags["labels"] then util.printout(descript.labels and table.concat(descript.labels, "\n")) | 105 | elseif flags["labels"] then util.printout(descript.labels and table.concat(descript.labels, "\n")) |
106 | elseif flags["modules"] then util.printout(keys_as_string(minfo.modules, "\n")) | 106 | elseif flags["modules"] then util.printout(keys_as_string(minfo.modules, "\n")) |
107 | elseif flags["deps"] then util.printout(keys_as_string(minfo.dependencies)) | 107 | elseif flags["deps"] then util.printout(keys_as_string(minfo.dependencies or {})) |
108 | elseif flags["rockspec"] then util.printout(rockspec_file) | 108 | elseif flags["rockspec"] then util.printout(rockspec_file) |
109 | elseif flags["mversion"] then util.printout(version) | 109 | elseif flags["mversion"] then util.printout(version) |
110 | else | 110 | else |
@@ -151,7 +151,7 @@ function show.command(flags, name, version) | |||
151 | end | 151 | end |
152 | end | 152 | end |
153 | local has_indirect_deps | 153 | local has_indirect_deps |
154 | for dep_name in util.sortedpairs(minfo.dependencies) do | 154 | for dep_name in util.sortedpairs(minfo.dependencies or {}) do |
155 | if not direct_deps[dep_name] then | 155 | if not direct_deps[dep_name] then |
156 | if not has_indirect_deps then | 156 | if not has_indirect_deps then |
157 | util.printout() | 157 | util.printout() |