]> git.e2factory.org Git - e2factory.git/commitdiff
cache: transport.fetch_file does not take a flags argument
authorTobias Ulmer <tu@emlix.com>
Fri, 6 Dec 2013 14:22:17 +0000 (15:22 +0100)
committerTobias Ulmer <tu@emlix.com>
Wed, 16 Nov 2016 14:41:17 +0000 (15:41 +0100)
Signed-off-by: Tobias Ulmer <tu@emlix.com>
generic/cache.lua

index dc5690f6c86ec42b47e5da9557817a3dcbdce40d..fe943c808792f22d40a960b8e4750efce4b7042b 100644 (file)
@@ -315,16 +315,14 @@ function cache.fetch_file(c, server, location, destdir, destname, flags)
         if not rc then
             return false, e:cat(re)
         end
-        rc, re = transport.fetch_file(ce.cache_url, location,
-        destdir, destname, flags)
+        rc, re = transport.fetch_file(ce.cache_url, location, destdir, destname)
         if not rc then
             return false, e:cat(re)
         end
     else
         -- cache is disabled:
         -- fetch from source to destination
-        rc, re = transport.fetch_file(ce.remote_url, location,
-        destdir, destname, flags)
+        rc, re = transport.fetch_file(ce.remote_url, location, destdir, destname)
         if not rc then
             return false, e:cat(re)
         end
@@ -441,8 +439,7 @@ function cache.cache_file(c, server, location, flags)
         -- file is in the cache and no refresh requested
         return true, nil
     end
-    local destdir = string.format("/%s/%s", ceurl.path,
-    e2lib.dirname(location))
+    local destdir = e2lib.join("/", ceurl.path, e2lib.dirname(location))
     -- fetch the file to the cache
     rc, re = transport.fetch_file(ce.remote_url, location, destdir, nil)
     if not rc then