Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
add bbox param back to BasicReader

Co-authored-by: Greg Lucas <[email protected]>
  • Loading branch information
lgolston and greglucas authored Aug 20, 2023
1 parent ff257c2 commit 1b242a7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/cartopy/io/shapereader.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,9 +133,9 @@ class BasicReader:
"""

def __init__(self, filename, **kwargs):
def __init__(self, filename, bbox=None, **kwargs):
# Validate the filename/shapefile
self._reader = reader = shapefile.Reader(filename, **kwargs)
self._reader = reader = shapefile.Reader(filename, bbox=bbox, **kwargs)
if reader.shp is None or reader.shx is None or reader.dbf is None:
raise ValueError("Incomplete shapefile definition "
"in '%s'." % filename)
Expand Down

0 comments on commit 1b242a7

Please sign in to comment.