mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +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