Skip to content

Commit c405b32

Browse files
committed
Emit messages on connect and disconnect
1 parent 7a97bfc commit c405b32

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/databases/firestore.js

+2
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,14 @@ _.extend(Firestore.prototype, {
4545
var self = this;
4646
var options = this.options;
4747
self.db = new gcFirestore(options);
48+
self.emit('connect');
4849
if (callback) callback(null, self);
4950
},
5051

5152
disconnect: function (callback) {
5253
var self = this;
5354
delete self.db;
55+
self.emit('disconnect');
5456
if (callback) callback(null, self);
5557
},
5658

0 commit comments

Comments
 (0)