Browse Source

Set device to None when user==device in astdb

Hal De 4 years ago
parent
commit
71ff1999d7
1 changed files with 1 additions and 1 deletions
  1. 1 1
      app/app.py

+ 1 - 1
app/app.py

@@ -699,7 +699,7 @@ class UsersDevices(Resource):
     data = {}
     data = {}
     for user in app.cache['ustates']:
     for user in app.cache['ustates']:
       device = await getUserDevice(user)
       device = await getUserDevice(user)
-      if device in NONEs:
+      if ((device in NONEs) or (device == user)):
         device = None
         device = None
       data[user]=device
       data[user]=device
     return successReply(data)
     return successReply(data)