diff --git a/productivity/driver.py b/productivity/driver.py index 4476383..68f9159 100644 --- a/productivity/driver.py +++ b/productivity/driver.py @@ -127,7 +127,7 @@ async def _parse_set_args(self, data_dict: Optional[dict], for key, value in to_write.items(): start_address = self.tags[key]['address']['start'] data_type = self.tags[key]['type'].rstrip(digits) - if type(value) == int and data_type == 'float': + if isinstance(value, int) and data_type == 'float': value = float(value) if type(value) != pydoc.locate(data_type): raise ValueError(f"Expected {key} to be a {data_type}.")