mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-02-09 09:16:41 +08:00
Fixing potential NRE in transaction manager
This commit is contained in:
@@ -53,9 +53,13 @@ namespace Orchard.Data {
|
||||
EnsureSession();
|
||||
|
||||
if (_cancelled) {
|
||||
_transaction.Rollback();
|
||||
_transaction.Dispose();
|
||||
_transaction = null;
|
||||
if (_transaction != null) {
|
||||
_transaction.Rollback();
|
||||
_transaction.Dispose();
|
||||
_transaction = null;
|
||||
}
|
||||
|
||||
_cancelled = false;
|
||||
}
|
||||
else {
|
||||
if (_transaction != null) {
|
||||
|
||||
Reference in New Issue
Block a user