From 6cb37a1c73fd9f8b23565725f835b84e9872cf29 Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Wed, 24 Jun 2015 17:17:30 -0300 Subject: Don't shadow filename variable: fixes error message. --- src/luarocks/fetch.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/luarocks/fetch.lua b/src/luarocks/fetch.lua index 83c76c9c..686aadcd 100644 --- a/src/luarocks/fetch.lua +++ b/src/luarocks/fetch.lua @@ -37,11 +37,11 @@ function fetch.fetch_url(url, filename, cache) if protocol == "file" then return fs.absolute_name(pathname) elseif fetch.is_basic_protocol(protocol, true) then - local ok, filename = fs.download(url, filename, cache) + local ok, name = fs.download(url, filename, cache) if not ok then return nil, "Failed downloading "..url..(filename and " - "..filename or ""), "network" end - return filename + return name else return nil, "Unsupported protocol "..protocol end -- cgit v1.2.3-55-g6feb