diff --git a/lib/src/dbs/executor.rs b/lib/src/dbs/executor.rs index 2ed09397..dbca50ea 100644 --- a/lib/src/dbs/executor.rs +++ b/lib/src/dbs/executor.rs @@ -220,7 +220,10 @@ impl<'a> Executor<'a> { _ => break, } // Cancel transaction - self.cancel(loc).await; + match stm.writeable() { + true => self.commit(loc).await, + false => self.cancel(loc).await, + }; // Return nothing Ok(Value::None) }