mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-01 12:42:48 +08:00
改进Connection类的事务方法
This commit is contained in:
@@ -545,9 +545,9 @@ abstract class Connection
|
||||
}
|
||||
$this->commit($label);
|
||||
return $result;
|
||||
} catch (\PDOException $e) {
|
||||
} catch (\Exception $e) {
|
||||
$this->rollback();
|
||||
return false;
|
||||
throw $e;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -570,7 +570,7 @@ abstract class Connection
|
||||
$this->linkID->beginTransaction();
|
||||
}
|
||||
$this->transTimes++;
|
||||
return null;
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user