Skip to content

Commit

Permalink
Make sure that stats always has the key "closed"
Browse files Browse the repository at this point in the history
  • Loading branch information
lordi committed Oct 16, 2017
1 parent 4734de9 commit 8f9c294
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion syncrypt/backends/binary.py
Original file line number Diff line number Diff line change
Expand Up @@ -776,7 +776,7 @@ def init(self):
self.slots = [BinaryStorageConnection(self) for i in range(self.concurrency)]

def get_stats(self):
states = {}
states = {'closed': 0}
if self.slots:
for conn in self.slots:
states[conn.state] = states.get(conn.state, 0) + 1
Expand Down

0 comments on commit 8f9c294

Please sign in to comment.