Fix bug where faults in new devices never get saved
This commit is contained in:
1 parent
b7370a6fb9
commit
a254ebbe0c
1 file changed
+1
-1
+1
-1
@@ -683,7 +683,7 @@ syncFaults = (deviceId, faults, callback) ->
|
|||||||
)
|
)
|
||||||
|
|
||||||
for channel, fault of faults
|
for channel, fault of faults
|
||||||
continue if fault.retries == existingFaults[channel]?.retries
|
continue if existingFaults[channel]? and fault.retries == existingFaults[channel].retries
|
||||||
do (channel, fault) ->
|
do (channel, fault) ->
|
||||||
++ counter
|
++ counter
|
||||||
fault._id = "#{deviceId}:#{channel}"
|
fault._id = "#{deviceId}:#{channel}"
|
||||||
|
|||||||
Reference in new issue
Block a user