Skip to content

Commit

Permalink
Fix minzoom and maxzoom attribute error
Browse files Browse the repository at this point in the history
  • Loading branch information
giswqs committed Oct 24, 2024
1 parent 4ba30af commit f29f66b
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions localtileserver/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,17 @@ def band_names(self):

@property
def min_zoom(self):
return self.info.minzoom
if hasattr(self, "info"):
return self.info.minzoom
else:
return self.reader.minzoom

@property
def max_zoom(self):
return self.info.maxzoom
if hasattr(self, "info"):
return self.info.maxzoom
else:
return self.reader.maxzoom

@property
def default_zoom(self):
Expand Down

0 comments on commit f29f66b

Please sign in to comment.