Skip to content

Commit

Permalink
Fix build error when initial DB file is missing
Browse files Browse the repository at this point in the history
  • Loading branch information
lkrnac committed Apr 30, 2016
1 parent e01bbd1 commit 4412ad0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gulp/gulpfile-server.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ gulp.task("test-server-boot", ["pre-test"], (cb) => {

const restoreBackup = () => {
fs.stat(dbPathBckp, (err, stats) => {
if (stats.isFile()) {
if (stats && stats.isFile()) {
fsExtra.removeSync(dbPath);
fsExtra.move(dbPathBckp, dbPath, cb);
} else {
Expand Down

0 comments on commit 4412ad0

Please sign in to comment.