Do not try to write anything to sqlite after its closed

This commit is contained in:
Pavel Djundik 2018-03-14 08:45:52 +02:00 committed by GitHub
parent 74ccef02bf
commit 0af3f10997
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -73,6 +73,8 @@ class MessageStorage {
return;
}
this.isEnabled = false;
this.database.close((err) => {
if (err) {
log.error(`Failed to close sqlite database: ${err}`);