Closed jeffsf closed 1 year ago
diff --git a/src/pyDE1/scanner.py b/src/pyDE1/scanner.py
index 0e0423a..660bc6e 100644
--- a/src/pyDE1/scanner.py
+++ b/src/pyDE1/scanner.py
@@ -305,7 +305,7 @@ async def scan_from_api(timeout: Optional[Union[int, float, bool]]=None):
"Passing false for 'begin' is deprecated. "
"Pass a timeout in seconds or null to accept the default.")
return None
- elif timeout <= 0:
+ elif timeout is not None and timeout <= 0:
raise DE1ValueError(
f"Timeout must be greater than zero {timeout}")
Update the Bluetooth Scanning doc to match https://pyde1.readthedocs.io/en/latest/CHANGELOG.html#b1-2022-03-19
Make sure null, as per those docs, doesn't raise