Skip to content

Commit

Permalink
fix test regression brought by create/update/changeId/delete posthook (
Browse files Browse the repository at this point in the history
  • Loading branch information
David Coutadeur committed Dec 11, 2023
1 parent 505580e commit 62eda9f
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -212,22 +212,22 @@ public OutputFormat getPostHookOutputFormat() {
}

public Optional<String> getCreatePostHook() {
Optional<String> hook = Optional.ofNullable(conf.getHooks().getCreatePostHook()).filter(s -> !s.isEmpty());
Optional<String> hook = Optional.ofNullable(conf.getHooks()).map(o -> o.getCreatePostHook()).filter(s -> !s.isEmpty());
return hook;
}

public Optional<String> getDeletePostHook() {
Optional<String> hook = Optional.ofNullable(conf.getHooks().getDeletePostHook()).filter(s -> !s.isEmpty());
Optional<String> hook = Optional.ofNullable(conf.getHooks()).map(o -> o.getDeletePostHook()).filter(s -> !s.isEmpty());
return hook;
}

public Optional<String> getUpdatePostHook() {
Optional<String> hook = Optional.ofNullable(conf.getHooks().getUpdatePostHook()).filter(s -> !s.isEmpty());
Optional<String> hook = Optional.ofNullable(conf.getHooks()).map(o -> o.getUpdatePostHook()).filter(s -> !s.isEmpty());
return hook;
}

public Optional<String> getChangeIdPostHook() {
Optional<String> hook = Optional.ofNullable(conf.getHooks().getChangeIdPostHook()).filter(s -> !s.isEmpty());
Optional<String> hook = Optional.ofNullable(conf.getHooks()).map(o -> o.getChangeIdPostHook()).filter(s -> !s.isEmpty());
return hook;
}

Expand Down

0 comments on commit 62eda9f

Please sign in to comment.