Skip to content

Commit

Permalink
fix some sonar issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Thorsten Marx committed Sep 9, 2024
1 parent e9d3e34 commit 6e54d0f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@
*
* @author t.marx
*/
public record Action(String name, int priority, ActionFunction<?> function) implements Hook {
public record Action<T>(String name, int priority, ActionFunction<T> function) implements Hook {
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,15 @@ public <T> void registerAction(final String name, final ActionFunction<T> hookFu
}

public <T> void registerAction(final String name, final ActionFunction<T> hookFunction, int priority) {
actions.put(name, new Action(name, priority, hookFunction));
actions.put(name, new Action<>(name, priority, hookFunction));
}

public <T> void registerFilter(final String name, final FilterFunction<T> hookFunction) {
registerFilter(name, hookFunction, 10);
}

public <T> void registerFilter(final String name, final FilterFunction<T> hookFunction, int priority) {
filters.put(name, new Filter(name, priority, hookFunction));
filters.put(name, new Filter<>(name, priority, hookFunction));
}

public ActionContext<Object> execute(final String name) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
/**
*
* @author thmar
* @param <Q>
* @param <T>
*/
public interface QueryProvider<Q extends Query<T>, T> {

Expand Down

0 comments on commit 6e54d0f

Please sign in to comment.