From 94bf65620f37408a9dac89bd8f722ebf4fbbb81b Mon Sep 17 00:00:00 2001 From: yumoqing Date: Wed, 6 May 2020 17:50:41 +0800 Subject: [PATCH] bugfix --- sqlor/dbpools.py | 4 ++-- sqlor/sor.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sqlor/dbpools.py b/sqlor/dbpools.py index f7721fe..481278f 100644 --- a/sqlor/dbpools.py +++ b/sqlor/dbpools.py @@ -199,10 +199,10 @@ class DBPools: try: yield sqlor except: - if if sqlor and sqlor.dataChanged: + if sqlor and sqlor.dataChanged: sqlor.rollback() finally: - if sif sqlor and qlor.dataChanged: + if sqlor and qlor.dataChanged: sqlor.commit() await self.freeSqlor(sqlor) diff --git a/sqlor/sor.py b/sqlor/sor.py index cbef5e4..644bb2e 100644 --- a/sqlor/sor.py +++ b/sqlor/sor.py @@ -198,7 +198,7 @@ class SQLor(object): return (m_sql,newdata) - def getSQLType(self,sql): + def getSqlType(self,sql): """ return one of "qry", "dml" and "ddl" ddl change the database schema