Skip to content

Commit

Permalink
restore forecast
Browse files Browse the repository at this point in the history
Signed-off-by: Jan N. Klug <[email protected]>
  • Loading branch information
J-N-K committed May 17, 2023
1 parent f6df98a commit 9633490
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -480,8 +480,11 @@ public void scheduleNewTimeSeries(String itemName, TimeSeries timeSeries) {

public void addItem(Item item) {
if (persistenceService instanceof QueryablePersistenceService) {
if (UnDefType.NULL.equals(item.getState()) && getMatchingConfigurations(RESTORE)
.anyMatch(configuration -> appliesToItem(configuration, item))) {
if (UnDefType.NULL.equals(item.getState())
&& (getMatchingConfigurations(RESTORE)
.anyMatch(configuration -> appliesToItem(configuration, item)))
|| getMatchingConfigurations(FORECAST)
.anyMatch(configuration -> appliesToItem(configuration, item))) {
restoreItemStateIfPossible(item);
}
if (getMatchingConfigurations(FORECAST).anyMatch(configuration -> appliesToItem(configuration, item))) {
Expand Down

0 comments on commit 9633490

Please sign in to comment.