diff --git a/game/example-images/132-2048x1365.jpg b/game/example-images/132-2048x1365.jpg deleted file mode 100644 index 2093e06..0000000 Binary files a/game/example-images/132-2048x1365.jpg and /dev/null differ diff --git a/server/Game.js b/server/Game.js index ce0711d..6dc128d 100644 --- a/server/Game.js +++ b/server/Game.js @@ -25,7 +25,7 @@ function loadAllGames() { const contents = fs.readFileSync(file, 'utf-8') const game = JSON.parse(contents) if (typeof game.puzzle.data.started === 'undefined') { - game.puzzle.data.started = Math.round(fs.statSync(file).atimeMs) + game.puzzle.data.started = Math.round(fs.statSync(file).ctimeMs) } if (typeof game.puzzle.data.finished === 'undefined') { let unfinished = game.puzzle.tiles.map(Util.decodeTile).find(t => t.owner !== -1) diff --git a/server/index.js b/server/index.js index 2f1647a..8b315ab 100644 --- a/server/index.js +++ b/server/index.js @@ -11,14 +11,14 @@ import twing from 'twing' import bodyParser from 'body-parser' const allImages = () => [ - ...fs.readdirSync('./../game/example-images/').map(f => ({ - file: `./../game/example-images/${f}`, - url: `/example-images/${f}`, - })), ...fs.readdirSync('./../data/uploads/').map(f => ({ file: `./../data/uploads/${f}`, url: `/uploads/${f}`, })), + ...fs.readdirSync('./../game/example-images/').map(f => ({ + file: `./../game/example-images/${f}`, + url: `/example-images/${f}`, + })), ] const port = config.http.port