summaryrefslogtreecommitdiffstats
path: root/lisp/lisp2vpp/src/main/java/io/fd/hc2vpp/lisp/translate/service/LispStateCheckServiceImpl.java
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/lisp2vpp/src/main/java/io/fd/hc2vpp/lisp/translate/service/LispStateCheckServiceImpl.java')
-rw-r--r--lisp/lisp2vpp/src/main/java/io/fd/hc2vpp/lisp/translate/service/LispStateCheckServiceImpl.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/lisp2vpp/src/main/java/io/fd/hc2vpp/lisp/translate/service/LispStateCheckServiceImpl.java b/lisp/lisp2vpp/src/main/java/io/fd/hc2vpp/lisp/translate/service/LispStateCheckServiceImpl.java
index d6bad6403..6bb5ca56e 100644
--- a/lisp/lisp2vpp/src/main/java/io/fd/hc2vpp/lisp/translate/service/LispStateCheckServiceImpl.java
+++ b/lisp/lisp2vpp/src/main/java/io/fd/hc2vpp/lisp/translate/service/LispStateCheckServiceImpl.java
@@ -55,14 +55,14 @@ public final class LispStateCheckServiceImpl implements LispStateCheckService, J
public void checkLispEnabledBefore(@Nonnull final WriteContext ctx) {
// no need to dump here, can be read directly from context
checkState(ctx.readBefore(InstanceIdentifier.create(Lisp.class))
- .or(STATIC_LISP_INSTANCE).isEnable(), "Lisp feature not enabled");
+ .orElse(STATIC_LISP_INSTANCE).isEnable(), "Lisp feature not enabled");
}
@Override
public void checkLispEnabledAfter(@Nonnull final WriteContext ctx) {
// no need to dump here, can be read directly from context
checkState(ctx.readAfter(InstanceIdentifier.create(Lisp.class))
- .or(STATIC_LISP_INSTANCE).isEnable(), "Lisp feature not enabled");
+ .orElse(STATIC_LISP_INSTANCE).isEnable(), "Lisp feature not enabled");
}
@Override
@@ -70,7 +70,7 @@ public final class LispStateCheckServiceImpl implements LispStateCheckService, J
// in this case it must be dumped
try {
return byteToBoolean(dumpManager.getDump(IDENTIFIER, ctx.getModificationCache())
- .or(DEFAULT_REPLY).featureStatus);
+ .orElse(DEFAULT_REPLY).featureStatus);
} catch (ReadFailedException e) {
throw new IllegalStateException("Unable to read Lisp Feature status", e);
}