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 16, 2023
1 parent 68fe0cd commit e347f51
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 e347f51

Please sign in to comment.