equal
deleted
inserted
replaced
32 end |
32 end |
33 end |
33 end |
34 if not oldest_uploads then break end |
34 if not oldest_uploads then break end |
35 local item = table.remove(oldest_uploads, 1); |
35 local item = table.remove(oldest_uploads, 1); |
36 local source_directory = paths.join(legacy_storage_path, item.dir); |
36 local source_directory = paths.join(legacy_storage_path, item.dir); |
37 local source_filename = paths.join(source_directory, item.dir, item.filename); |
37 local source_filename = paths.join(source_directory, item.filename); |
38 local target_filename = dm.getpath(item.dir, component, "http_file_share", "bin", true); |
38 local target_filename = dm.getpath(item.dir, component, "http_file_share", "bin", true); |
39 if not lfs.attributes(source_filename, "mode") then |
39 if not lfs.attributes(source_filename, "mode") then |
40 print("Not migrating missing file " .. source_filename); |
40 print("Not migrating missing file " .. source_filename); |
41 else |
41 else |
42 print("Moving " .. source_filename .. " to " .. target_filename .. " for " .. uploader); |
42 print("Moving " .. source_filename .. " to " .. target_filename .. " for " .. uploader); |