File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
main/java/io/engagingspaces/vertx/dataloader
test/java/io/engagingspaces/vertx/dataloader Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -100,7 +100,7 @@ public Future<V> load(K key) {
100100 } else {
101101 CompositeFuture compositeFuture = batchLoadFunction .load (Collections .singleton (key ));
102102 if (compositeFuture .succeeded ()) {
103- future .complete (compositeFuture .result ().result (0 ));
103+ future .complete (compositeFuture .result ().resultAt (0 ));
104104 } else {
105105 future .fail (compositeFuture .cause ());
106106 }
@@ -141,7 +141,7 @@ public CompositeFuture dispatch() {
141141 AtomicInteger index = new AtomicInteger (0 );
142142 loaderQueue .forEach ((key , future ) -> {
143143 if (batch .succeeded (index .get ())) {
144- future .complete (batch .result (index .get ()));
144+ future .complete (batch .resultAt (index .get ()));
145145 } else {
146146 future .fail (batch .cause (index .get ()));
147147 }
Original file line number Diff line number Diff line change @@ -445,8 +445,8 @@ public void should_Accept_objects_as_keys() {
445445
446446 identityLoader .dispatch ().setHandler (rh -> {
447447 assertThat (rh .succeeded (), is (true ));
448- assertThat (rh .result ().result (0 ), equalTo (keyA ));
449- assertThat (rh .result ().result (1 ), equalTo (keyB ));
448+ assertThat (rh .result ().resultAt (0 ), equalTo (keyA ));
449+ assertThat (rh .result ().resultAt (1 ), equalTo (keyB ));
450450 });
451451
452452 assertThat (loadCalls .size (), equalTo (1 ));
@@ -464,7 +464,7 @@ public void should_Accept_objects_as_keys() {
464464
465465 identityLoader .dispatch ().setHandler (rh -> {
466466 assertThat (rh .succeeded (), is (true ));
467- assertThat (rh .result ().result (0 ), equalTo (keyA ));
467+ assertThat (rh .result ().resultAt (0 ), equalTo (keyA ));
468468 assertThat (identityLoader .getCacheKey (keyB ), equalTo (keyB ));
469469 });
470470
You can’t perform that action at this time.
0 commit comments