repos: Fix BuildReporter caching

This commit is contained in:
Ivan A. Melnikov 2024-12-20 13:05:30 +04:00
parent 573c9ae458
commit a7df65c0e4

View File

@ -453,15 +453,15 @@ class BuildReporter:
self._warned_on.add(subject)
def report(self, source_name):
if self._cache:
if self._cache is not None:
cached_result = self._cache.get(source_name)
if cached_result:
return cached_result
report = self._raw_report(source_name)
if self._cache:
self.cache[source_name] = report
if self._cache is not None:
self._cache[source_name] = report
return report
def _same_source(self, source_name):