Skip to content

Commit

Permalink
feat: implementation of "X-Userlevel" header to prevent "installer ac…
Browse files Browse the repository at this point in the history
…count" conflict #108 #132
  • Loading branch information
petrleocompel committed Oct 15, 2024
1 parent 7d8aa07 commit b03663c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion custom_components/hikvision_axpro/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
code = entry.data[CONF_CODE]
use_code_arming = entry.data[USE_CODE_ARMING]
use_sub_systems = entry.data.get(ALLOW_SUBSYSTEMS, False)
axpro = hikaxpro.HikAxPro(host, username, password)
axpro = hikaxpro.HikAxPro(host, username, password, user_level=hikaxpro.USER_LEVEL_ADMIN_OPERATOR)
if entry.data.get(INTERNAL_API):
axpro = hikax.HikAx(host, username, password)
update_interval: float = entry.data.get(CONF_SCAN_INTERVAL, SCAN_INTERVAL.total_seconds())
Expand Down
2 changes: 1 addition & 1 deletion custom_components/hikvision_axpro/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"iot_class": "local_polling",
"issue_tracker": "https://github.com/petrleocompel/hikaxpro_hacs/issues",
"requirements": [
"hikaxpro==2.2.1",
"hikaxpro==2.3.0",
"requests"
],
"version": "2.2.2"
Expand Down
2 changes: 1 addition & 1 deletion test_requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
hikaxpro==2.2.1
hikaxpro==2.3.0
homeassistant
xmltodict
pytest
Expand Down

0 comments on commit b03663c

Please sign in to comment.