From 92d254846cebbd01949b3368603da983a47945ee Mon Sep 17 00:00:00 2001 From: Ladislav Thon Date: Thu, 5 Dec 2024 12:25:36 +0100 Subject: [PATCH] fix the example in the documentation index page --- doc/modules/ROOT/pages/index.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/modules/ROOT/pages/index.adoc b/doc/modules/ROOT/pages/index.adoc index eaa79f01..9a047d2e 100644 --- a/doc/modules/ROOT/pages/index.adoc +++ b/doc/modules/ROOT/pages/index.adoc @@ -22,12 +22,12 @@ It also provides a programmatic API to build reusable guards: [source,java] ---- public class MyService { - private static final FaultTolerance guard = FaultTolerance.create() + private static final TypedGuard GUARD = TypedGuard.create(String.class) .withFallback().handler(() -> "fallback").done() // <1> .build(); public String hello() throws Exception { - return guard.call(() -> externalService.hello()); // <2> + return GUARD.call(() -> externalService.hello()); // <2> } } ----