Compare commits
2 Commits
5a91c89730
...
7df864b95d
Author | SHA1 | Date | |
---|---|---|---|
7df864b95d | |||
b1637ad857 |
@ -71,7 +71,8 @@ function scanDir(parent, path) {
|
||||
let filepath = path + file;
|
||||
return stat(filepath).then(function(stats) {
|
||||
if (stats.isDirectory()) {
|
||||
return scanDir(album, filepath + "/").spread(function(_albums, _assets) {
|
||||
return scanDir(album, filepath + "/")
|
||||
.then(([ _albums, _assets ]) => {
|
||||
albums = albums.concat(_albums);
|
||||
assets = assets.concat(_assets);
|
||||
});
|
||||
@ -108,7 +109,8 @@ function scanDir(parent, path) {
|
||||
|
||||
require("./server/db/photos").then(function(db) {
|
||||
photoDB = db;
|
||||
return scanDir(null, picturesPath).spread(function(albums, assets) {
|
||||
return scanDir(null, picturesPath)
|
||||
.then(([ albums, assets ]) => {
|
||||
console.log(assets.length + " assets have incorrect dates.");
|
||||
let toProcess = assets.length, lastMessage = moment(), started = moment();
|
||||
return photoDB.sequelize.transaction(function (t) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user