Looks like the DB needs ready: false on device absence or plugged in devices show up as immediately available. That's a bug, will need to investigate later.

This commit is contained in:
Simo Kinnunen
2015-06-02 16:14:39 +09:00
parent 2ec03798a4
commit 11a042d0aa

View File

@@ -163,6 +163,7 @@ dbapi.unsetDeviceOwner = function(serial) {
dbapi.setDeviceAbsent = function(serial) {
return db.run(r.table('devices').get(serial).update({
present: false
, ready: false
}))
}