From fe9a766ada1befdda9364f7070e02ff7165e9f26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Heredero?= Date: Thu, 15 Jun 2023 17:26:33 +0200 Subject: [PATCH] really small polish --- src/main/java/ch/hevs/isi/db/DatabaseConnector.java | 3 +-- src/test/java/Database.java | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/main/java/ch/hevs/isi/db/DatabaseConnector.java b/src/main/java/ch/hevs/isi/db/DatabaseConnector.java index f5b363b..61580b3 100644 --- a/src/main/java/ch/hevs/isi/db/DatabaseConnector.java +++ b/src/main/java/ch/hevs/isi/db/DatabaseConnector.java @@ -76,7 +76,7 @@ public class DatabaseConnector implements DataPointListener { */ public void initialize(String url){ // Full URL of the InfluxDB server - String fullURL = null; + String fullURL; try{ if(urlForWrite == null){ if(url == null){ @@ -118,7 +118,6 @@ public class DatabaseConnector implements DataPointListener { data += "}"; Utility.pDebug(data); sendDataToDatabase(data); - fullURL =null; // Reset the full URL } } diff --git a/src/test/java/Database.java b/src/test/java/Database.java index d5518ad..ad8e26e 100644 --- a/src/test/java/Database.java +++ b/src/test/java/Database.java @@ -1,5 +1,4 @@ import ch.hevs.isi.MinecraftController; -import ch.hevs.isi.core.BooleanDataPoint; import ch.hevs.isi.core.FloatDataPoint; import ch.hevs.isi.db.DatabaseConnector; @@ -25,7 +24,7 @@ public class Database { // Set the grid voltage to 750 // and make a sawtooth from 750 to 850 and back to 750 in 30 steps for (float i = 0; i < 3; i += 0.1f) { - System.out.println(""); + System.out.println(); clock.setValue(i); gridVoltage.setValue(750 + (100*i)%100); }