File tree Expand file tree Collapse file tree
Extensions/Xtensive.Orm.BulkOperations/Internals Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -45,8 +45,10 @@ protected async override Task<int> ExecuteInternalAsync(CancellationToken token
4545 var request = GetRequest ( query ) ;
4646 Bindings = request . ParameterBindings . ToList ( ) ;
4747
48- await using var command = CreateCommand ( request ) ;
49- return await command . ExecuteNonQueryAsync ( token ) . ConfigureAwait ( false ) ;
48+ var command = CreateCommand ( request ) ;
49+ await using ( command . ConfigureAwait ( false ) ) {
50+ return await command . ExecuteNonQueryAsync ( token ) . ConfigureAwait ( false ) ;
51+ }
5052 }
5153
5254 private QueryCommand CreateCommand ( QueryTranslationResult request )
Original file line number Diff line number Diff line change @@ -48,8 +48,10 @@ protected async override Task<int> ExecuteInternalAsync(CancellationToken token
4848 var request = GetRequest ( query ) ;
4949 Bindings = request . ParameterBindings . ToList ( ) ;
5050
51- await using var command = CreateCommand ( request ) ;
52- return await command . ExecuteNonQueryAsync ( token ) . ConfigureAwait ( false ) ;
51+ var command = CreateCommand ( request ) ;
52+ await using ( command . ConfigureAwait ( false ) ) {
53+ return await command . ExecuteNonQueryAsync ( token ) . ConfigureAwait ( false ) ;
54+ }
5355 }
5456
5557 private QueryCommand CreateCommand ( QueryTranslationResult request )
Original file line number Diff line number Diff line change @@ -39,8 +39,10 @@ protected async override Task<int> ExecuteInternalAsync(CancellationToken token
3939 }
4040 Bindings = new List < QueryParameterBinding > ( ) ;
4141
42- await using var command = CreateCommand ( ) ;
43- return await command . ExecuteNonQueryAsync ( token ) . ConfigureAwait ( false ) ;
42+ var command = CreateCommand ( ) ;
43+ await using ( command . ConfigureAwait ( false ) ) {
44+ return await command . ExecuteNonQueryAsync ( token ) . ConfigureAwait ( false ) ;
45+ }
4446 }
4547
4648 private QueryCommand CreateCommand ( )
You can’t perform that action at this time.
0 commit comments