mirror of https://github.com/status-im/codimd.git
Add to throw error when server not ready after db synced
This commit is contained in:
parent
b5920fbbd1
commit
b9c4af8a65
2
app.js
2
app.js
|
@ -487,6 +487,8 @@ models.sequelize.sync().then(function () {
|
||||||
if (err) throw new Error(err);
|
if (err) throw new Error(err);
|
||||||
if (!notes || notes.length <= 0) return startListen();
|
if (!notes || notes.length <= 0) return startListen();
|
||||||
});
|
});
|
||||||
|
} else {
|
||||||
|
throw new Error('server still not ready after db synced');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue