Skip to content

Commit

Permalink
Close milestone database when calling Backend.close
Browse files Browse the repository at this point in the history
  • Loading branch information
Alec Gibson committed Aug 23, 2018
1 parent 0249c91 commit c1f58a5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/backend.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ Backend.prototype._shimAfterSubmit = function() {
};

Backend.prototype.close = function(callback) {
var wait = 3;
var wait = 4;
var backend = this;
function finish(err) {
if (err) {
Expand All @@ -119,6 +119,7 @@ Backend.prototype.close = function(callback) {
}
this.pubsub.close(finish);
this.db.close(finish);
this.milestoneDb.close(finish);
for (var name in this.extraDbs) {
wait++;
this.extraDbs[name].close(finish);
Expand Down

0 comments on commit c1f58a5

Please sign in to comment.