@@ -159,7 +159,7 @@ void testBasicVariations2() {
159
159
async (1 , c );
160
160
}).thenRun (c -> {
161
161
plain (2 );
162
- c .complete ();
162
+ c .complete (c );
163
163
}).finish (callback );
164
164
});
165
165
@@ -419,7 +419,7 @@ void testPlain() {
419
419
(callback ) -> {
420
420
beginAsync ().thenRun (c -> {
421
421
plain (1 );
422
- c .complete ();
422
+ c .complete (c );
423
423
}).finish (callback );
424
424
});
425
425
}
@@ -457,7 +457,7 @@ void testTryCatch() {
457
457
async (1 , c );
458
458
}).onErrorIf (t -> true , (t , c ) -> {
459
459
plain (2 );
460
- c .complete ();
460
+ c .complete (c );
461
461
}).finish (callback );
462
462
});
463
463
@@ -602,7 +602,7 @@ void testTryCatchWithVariables() {
602
602
final int [] i = new int [1 ];
603
603
beginAsync ().thenRun (c -> {
604
604
i [0 ] = plainTest (0 ) ? 1 : 2 ;
605
- c .complete ();
605
+ c .complete (c );
606
606
}).thenRun (c -> {
607
607
beginAsync ().<Integer >thenSupply (c2 -> {
608
608
asyncReturns (i [0 ] + 10 , c2 );
@@ -818,7 +818,7 @@ void testDerivation() {
818
818
};
819
819
BiConsumer <Integer , SingleResultCallback <Void >> happyAsync = (i , c ) -> {
820
820
happySync .accept (i );
821
- c .complete ();
821
+ c .complete (c );
822
822
};
823
823
824
824
// Standard nested async, no error handling:
@@ -955,12 +955,12 @@ private Integer syncReturns(final int i) {
955
955
private void async (final int i , final SingleResultCallback <Void > callback ) {
956
956
if (throwExceptionsFromAsync ) {
957
957
sync (i );
958
- callback .complete ();
958
+ callback .complete (callback );
959
959
960
960
} else {
961
961
try {
962
962
sync (i );
963
- callback .complete ();
963
+ callback .complete (callback );
964
964
} catch (Throwable t ) {
965
965
callback .onResult (null , t );
966
966
}
0 commit comments