diff --git a/recommendations/RoofRecommendations.py b/recommendations/RoofRecommendations.py index 8878b465..c37c4d85 100644 --- a/recommendations/RoofRecommendations.py +++ b/recommendations/RoofRecommendations.py @@ -79,13 +79,13 @@ class RoofRecommendations: return self.recommendations - def is_loft_already_insulated(self): + def is_loft_already_insulated(self, measures): """ Check if the loft is already insulated """ # If we have a non-invasive recommendation for the loft insulation, we can assume that the loft is not insulated - if "loft_insulation" in self.property.non_invasive_recommendations: + if "loft_insulation" in measures: return False return (self.insulation_thickness > self.MINIMUM_LOFT_ISULATION_MM) and self.property.roof["is_pitched"] @@ -123,7 +123,7 @@ class RoofRecommendations: # Building regulations part L recommend installing at least 270mm of insulation, however generally we # experience diminishing returns in terms of SAP once we go beyond around 150mm of insulation # This only holds true for pitched roofs. - if self.is_loft_already_insulated(): + if self.is_loft_already_insulated(measures): return if (self.insulation_thickness >= self.MINIMUM_FLAT_ROOF_ISULATION_MM) and self.property.roof["is_flat"]: