[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:
@@ -98,13 +98,14 @@ public class SensiboAccountHandler extends BaseBridgeHandler {
|
||||
|
||||
gson = new GsonBuilder().registerTypeAdapter(ZonedDateTime.class, new TypeAdapter<ZonedDateTime>() {
|
||||
@Override
|
||||
public void write(final @NonNullByDefault({}) JsonWriter out, final ZonedDateTime value)
|
||||
throws IOException {
|
||||
out.value(value.toString());
|
||||
public void write(JsonWriter out, @Nullable ZonedDateTime value) throws IOException {
|
||||
if (value != null) {
|
||||
out.value(value.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public ZonedDateTime read(final @NonNullByDefault({}) JsonReader in) throws IOException {
|
||||
public @Nullable ZonedDateTime read(final JsonReader in) throws IOException {
|
||||
return ZonedDateTime.parse(in.nextString());
|
||||
}
|
||||
}).setLenient().setPrettyPrinting().create();
|
||||
|
||||
Reference in New Issue
Block a user