Skip to content

Commit 922e791

Browse files
authored
Remove a compilation warning (#6294)
1 parent ae3dc18 commit 922e791

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

core/src/main/java/org/apache/hop/core/gui/plugin/action/GuiActionLambdaBuilder.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public GuiAction createLambda(GuiAction guiAction, T methodParameter, IGuiRefres
6767

6868
try {
6969
Method getInstanceMethod = guiPluginClass.getDeclaredMethod("getInstance");
70-
guiPlugin = getInstanceMethod.invoke(null, null);
70+
guiPlugin = getInstanceMethod.invoke(null, (Object[]) null);
7171
} catch (Exception nsme) {
7272
// On the rebound we'll try to simply construct a new instance...
7373
// This makes the plugins even simpler.

ui/src/main/java/org/apache/hop/ui/hopgui/context/BaseGuiContextHandler.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ public Object getFilterObject(GuiActionFilter actionFilter) throws HopException
124124
Object guiPlugin;
125125
try {
126126
Method getInstanceMethod = filterClass.getDeclaredMethod("getInstance");
127-
guiPlugin = getInstanceMethod.invoke(null, null);
127+
guiPlugin = getInstanceMethod.invoke(null, (Object[]) null);
128128
} catch (Exception nsme) {
129129
// On the rebound we'll try to simply construct a new instance...
130130
// This makes the plugins even simpler.

ui/src/test/java/org/apache/hop/ui/core/bus/HopGuiEventsHandlerTest.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,8 @@ public void testAddEventExceptions() {
100100
// We need at least 1 non-null event ID
101101
//
102102
assertThrows(RuntimeException.class, () -> events.addEventListener("guiId-1", e -> {}));
103-
assertThrows(RuntimeException.class, () -> events.addEventListener("guiId-1", e -> {}, null));
103+
assertThrows(
104+
RuntimeException.class, () -> events.addEventListener("guiId-1", e -> {}, (String[]) null));
104105
assertThrows(RuntimeException.class, () -> events.addEventListener("guiId-1", e -> {}, ""));
105106
}
106107

@@ -110,7 +111,7 @@ public void testFireEventExceptions() {
110111
//
111112
assertThrows(RuntimeException.class, () -> events.fire());
112113
assertThrows(RuntimeException.class, () -> events.fire(""));
113-
assertThrows(RuntimeException.class, () -> events.fire(null));
114+
assertThrows(RuntimeException.class, () -> events.fire((Object[]) null));
114115
}
115116

116117
@Test

0 commit comments

Comments
 (0)