debugging recommendation when we have independent boiler upgrade and heating controls

This commit is contained in:
Khalim Conn-Kowlessar 2024-04-19 14:07:47 +01:00
parent 3593b7ae9e
commit 391cb356ee

View file

@ -394,9 +394,13 @@ class HeatingRecommender:
controls_recommender.recommend(heating_description="Boiler and radiators, mains gas")
# We may have 2 recommendations from the heating controls
if not controls_recommender.recommendation:
if not controls_recommender.recommendation and not boiler_recommendation:
return
if not system_change and len(boiler_recommendation):
# If there is not a system change, we add the boiler recommendation at point.
self.recommendations.append(boiler_recommendation)
if system_change:
# We combine the heating and controls recommendations, in the case of a system change
combined_recommendations = []