Skip to content

Commit

Permalink
PersistenceExtensions: fix DateTimeException when persisting an empty…
Browse files Browse the repository at this point in the history
… TimeSeries (#4303)

Signed-off-by: Jimmy Tanagra <[email protected]>
  • Loading branch information
jimtng authored Jul 8, 2024
1 parent 21e605d commit ea7d61b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ public static void persist(Item item, TimeSeries timeSeries, @Nullable String se

private static void internalPersist(Item item, TimeSeries timeSeries, @Nullable String serviceId) {
String effectiveServiceId = serviceId == null ? getDefaultServiceId() : serviceId;
if (effectiveServiceId == null) {
if (effectiveServiceId == null || timeSeries.size() == 0) {
return;
}
PersistenceService service = getService(effectiveServiceId);
Expand Down

0 comments on commit ea7d61b

Please sign in to comment.