summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--django/core/db/backends/mysql.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/django/core/db/backends/mysql.py b/django/core/db/backends/mysql.py
index 4585600ce4..c51b357bec 100644
--- a/django/core/db/backends/mysql.py
+++ b/django/core/db/backends/mysql.py
@@ -35,10 +35,11 @@ class DatabaseWrapper:
return self.connection.cursor()
def commit(self):
- pass
+ self.connection.commit()
def rollback(self):
- pass
+ if self.connection:
+ self.connection.rollback()
def close(self):
if self.connection is not None: