Skip to content

Commit

Permalink
Don't use auto() for str enum
Browse files Browse the repository at this point in the history
  • Loading branch information
piitaya committed Nov 28, 2024
1 parent b0a67e9 commit a253cf0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions custom_components/eufy_security/alarm_control_panel.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ class CurrentModeToStateValue(Enum):
NONE = "Unknown"
AWAY = AlarmControlPanelState.ARMED_AWAY
HOME = AlarmControlPanelState.ARMED_HOME
CUSTOM_BYPASS = auto()
NIGHT = auto()
VACATION = auto()
CUSTOM_BYPASS = 3
NIGHT = 4
VACATION = 5
DISARMED = AlarmControlPanelState.DISARMED
OFF = STATE_OFF
TRIGGERED = AlarmControlPanelState.TRIGGERED
Expand Down
12 changes: 6 additions & 6 deletions custom_components/eufy_security/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,16 @@ class ConfigField(Enum):
host = "127.0.0.1"
port = 3000
sync_interval = 600 # seconds
rtsp_server_address = auto()
rtsp_server_address = 3
no_stream_in_hass = False
name_for_custom1 = "Custom 1"
name_for_custom2 = "Custom 2"
name_for_custom3 = "Custom 3"
captcha_id = auto()
captcha_img = auto()
captcha_input = auto()
mfa_required = auto()
mfa_input = auto()
captcha_id = 8
captcha_img = 9
captcha_input = 10
mfa_required = 11
mfa_input = 12


@dataclass
Expand Down

0 comments on commit a253cf0

Please sign in to comment.