Skip to content

Commit fff4eca

Browse files
committed
Use call rather than chain for session flush
Closes #2
1 parent 68ad9b8 commit fff4eca

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/io/vertx/howtos/hr/MainVerticle.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ private Uni<Product> createProduct(RoutingContext ctx) {
8383
Product product = ctx.getBodyAsJson().mapTo(Product.class);
8484
return emf.withSession(session -> session.
8585
persist(product)
86-
.chain(session::flush)
86+
.call(session::flush)
8787
.replaceWith(product));
8888
}
8989
// end::crud-methods[]

0 commit comments

Comments
 (0)