database: fix typo in sync implementation

Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
Eric Callahan 2022-02-13 14:15:16 -05:00
parent 3c92f42d49
commit c1104617b6
1 changed files with 3 additions and 3 deletions

View File

@ -475,11 +475,11 @@ class MoonrakerDatabase:
cursor.put(self._encode_value(value[key]))
new_keys.remove(key)
remaining = cursor.next()
for k in new_keys:
val = value[k]
for key in new_keys:
val = value[key]
ret = txn.put(key.encode(), self._encode_value(val))
if not ret:
logging.info(f"Error inserting key '{k}' "
logging.info(f"Error inserting key '{key}' "
f"in namespace '{namespace}'")
def ns_length(self, namespace: str) -> Future[int]: