aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/database/ResultSetConverter.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/database/ResultSetConverter.java')
-rw-r--r--src/org/traccar/database/ResultSetConverter.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/org/traccar/database/ResultSetConverter.java b/src/org/traccar/database/ResultSetConverter.java
index e4aec956c..92cb8fa4e 100644
--- a/src/org/traccar/database/ResultSetConverter.java
+++ b/src/org/traccar/database/ResultSetConverter.java
@@ -26,8 +26,6 @@ import javax.json.JsonArrayBuilder;
import javax.json.JsonObjectBuilder;
public class ResultSetConverter {
-
- private static final DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ssZ");
public static JsonArray convert(ResultSet rs) throws SQLException {
@@ -66,10 +64,10 @@ public class ResultSetConverter {
obj.add(columnName, rs.getString(columnName));
break;
case java.sql.Types.DATE:
- obj.add(columnName, dateFormat.format(rs.getDate(columnName)));
+ obj.add(columnName, JsonConvertable.dateFormat.format(rs.getDate(columnName)));
break;
case java.sql.Types.TIMESTAMP:
- obj.add(columnName, dateFormat.format(rs.getTimestamp(columnName)));
+ obj.add(columnName, JsonConvertable.dateFormat.format(rs.getTimestamp(columnName)));
break;
default:
break;