database: validate that namespace exists in ns_contains

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
Eric Callahan 2022-02-18 08:26:32 -05:00
parent 0bd12c8dec
commit 96b00549cf
1 changed files with 1 additions and 0 deletions

View File

@ -562,6 +562,7 @@ class MoonrakerDatabase:
namespace: str,
key: Union[List[str], str]
) -> bool:
self._get_db(namespace)
try:
key_list = self._process_key(key)
record = self._get_record(namespace, key_list[0])