[infrastructure] move infered nullness warnings to error and update EEA (#8949)
Signed-off-by: Jan N. Klug <jan.n.klug@rub.de>
This commit is contained in:
@@ -13,6 +13,7 @@
|
||||
package org.openhab.binding.wlanthermo.internal;
|
||||
|
||||
import java.net.URISyntaxException;
|
||||
import java.util.Objects;
|
||||
import java.util.concurrent.*;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
@@ -108,7 +109,7 @@ public class WlanThermoMiniHandler extends BaseThingHandler {
|
||||
try {
|
||||
// Update objects with data from device
|
||||
String json = httpClient.GET(config.getUri("/app.php")).getContentAsString();
|
||||
app = gson.fromJson(json, App.class);
|
||||
app = Objects.requireNonNull(gson.fromJson(json, App.class));
|
||||
logger.debug("Received at /app.php: {}", json);
|
||||
|
||||
// Update channels
|
||||
|
||||
@@ -14,6 +14,7 @@ package org.openhab.binding.wlanthermo.internal;
|
||||
|
||||
import java.net.URI;
|
||||
import java.net.URISyntaxException;
|
||||
import java.util.Objects;
|
||||
import java.util.concurrent.*;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
@@ -134,10 +135,10 @@ public class WlanThermoNanoHandler extends BaseThingHandler {
|
||||
try {
|
||||
// Update objects with data from device
|
||||
String json = httpClient.GET(config.getUri("/data")).getContentAsString();
|
||||
data = gson.fromJson(json, Data.class);
|
||||
data = Objects.requireNonNull(gson.fromJson(json, Data.class));
|
||||
logger.debug("Received at /data: {}", json);
|
||||
json = httpClient.GET(config.getUri("/settings")).getContentAsString();
|
||||
settings = gson.fromJson(json, Settings.class);
|
||||
settings = Objects.requireNonNull(gson.fromJson(json, Settings.class));
|
||||
logger.debug("Received at /settings: {}", json);
|
||||
|
||||
// Update channels
|
||||
|
||||
Reference in New Issue
Block a user