We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 04bd784 commit d6ef8faCopy full SHA for d6ef8fa
stac_fastapi/types/stac_fastapi/types/search.py
@@ -31,11 +31,14 @@ def str2list(x: str) -> Optional[List[str]]:
31
return None
32
33
34
-def str2bbox(x: str) -> BBox:
+def str2bbox(x: str) -> Optional[BBox]:
35
"""Convert string to BBox based on , delimiter."""
36
- t = tuple(float(v) for v in x.split(","))
37
- assert len(t) in [4, 6], f"BBox '{x}' must have 4 or 6 values."
38
- return t
+ if x:
+ t = tuple(float(v) for v in x.split(","))
+ assert len(t) in [4, 6], f"BBox '{x}' must have 4 or 6 values."
39
+ return t
40
+
41
+ return None
42
43
44
def _collection_converter(
0 commit comments