Skip to content

Commit

Permalink
return 0 for relays if not defined
Browse files Browse the repository at this point in the history
  • Loading branch information
pergolafabio committed Aug 30, 2023
1 parent e1cd273 commit e202885
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions hikvision-doorbell/src/doorbell.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,8 @@ def user_config() -> int:
if self._config.output_relays is not None:
logger.debug("Using the configured number of switches: {}", self._config.output_relays)
return self._config.output_relays
else:
return 0
raise RuntimeError("No user configuration specified")

# Define the list of available endpoints to try
Expand Down

0 comments on commit e202885

Please sign in to comment.