mirror of
https://github.com/zotero/zotero.git
synced 2026-10-09 03:18:01 +00:00
Allow a DB.rollbackTransaction() even if a transaction isn't in progress
This commit is contained in:
parent
02f205e919
commit
023e755eb6
1 changed files with 5 additions and 0 deletions
|
|
@ -320,6 +320,11 @@ Zotero.DB = new function(){
|
|||
function rollbackTransaction(){
|
||||
var db = _getDBConnection();
|
||||
|
||||
if (!db.transactionInProgress) {
|
||||
Zotero.debug("Transaction is not in progress in rollbackTransaction()", 2);
|
||||
return;
|
||||
}
|
||||
|
||||
if (_transactionNestingLevel){
|
||||
_transactionNestingLevel--;
|
||||
_transactionRollback = true;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue