Fix static analysis issues

This commit is contained in:
Ian Renton
2026-02-27 20:33:45 +00:00
parent 6982354364
commit 3792e9f4d9
17 changed files with 36 additions and 38 deletions

View File

@@ -44,7 +44,8 @@ class SpotProvider:
# Fill in any blanks and add to the list
spot.infer_missing()
self._add_spot(spot)
self.last_spot_time = datetime.fromtimestamp(max(map(lambda s: s.time, spots)), pytz.UTC)
if spots:
self.last_spot_time = datetime.fromtimestamp(max(map(lambda s: s.time, spots)), pytz.UTC)
def _submit(self, spot):
"""Submit a single spot retrieved from the provider. This will be added to the list regardless of its age. Spots