Przeglądaj źródła

EmComponents: close db connexion after fetching (sqlite issue)

ArnAud 10 lat temu
rodzic
commit
ac6a2883f2
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1
    1
      EditorialModel/components.py

+ 1
- 1
EditorialModel/components.py Wyświetl plik

@@ -85,9 +85,9 @@ class EmComponent(object):
85 85
             req = req.where(component.c.uid == self.uid)
86 86
         c = dbe.connect()
87 87
         res = c.execute(req)
88
-        c.close()
89 88
 
90 89
         res = res.fetchall()
90
+        c.close()
91 91
 
92 92
         if not res or len(res) == 0:
93 93
             raise EmComponentNotExistError("No component found with "+('name ' + self.name if self.uid == None else 'uid ' + str(self.uid) ))

Loading…
Anuluj
Zapisz