Explorar o código

HUE-3293 [core] Prevent document matching query error when going one home 1

Romain Rigaux %!s(int64=9) %!d(string=hai) anos
pai
achega
2ba34a7
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      desktop/core/src/desktop/api.py

+ 1 - 1
desktop/core/src/desktop/api.py

@@ -38,7 +38,7 @@ def _get_docs(user):
   history_tag = DocumentTag.objects.get_history_tag(user)
 
   dir_ids = [directory.doc.get().id for directory in Directory.objects.filter(doc__isnull=False)]
-  editor_ids = [document.doc.get().id for document in Document2.objects.filter(type__startswith='query')]
+  editor_ids = [document.doc.get().id for document in Document2.objects.filter(type__startswith='query', doc__isnull=False)]
 
   query = Document.objects.get_docs(user) \
       .exclude(tags__in=[history_tag]) \