Increased logic for repeat type

pull/11/head
Nicholas Hope 2022-06-20 20:42:07 -04:00
parent 5fbd0f75a2
commit a3980e9aab
1 changed files with 3 additions and 1 deletions

View File

@ -151,7 +151,9 @@ def removeRelaventFields(data, bindType):
errMsgs.append("Repeat requires interval")
else:
interval = content["interval"]
if unit == "t" and isinstance(interval, float):
if interval < 0:
errMsgs.append("Repeat interval cannot be negative")
if (unit == "t" and not isinstance(interval, int)):
errMsgs.append("Repeat interval must be integer if unit is ticks")
return data, errMsgs