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: