Change motionEye to use a two item device identifier tuple (#49774)
* Change to a two item device identifier tuple. * Don't use join.
This commit is contained in:
parent
513685bbea
commit
3fda66d9e2
2 changed files with 3 additions and 3 deletions
|
@ -52,9 +52,9 @@ def create_motioneye_client(
|
|||
|
||||
def get_motioneye_device_identifier(
|
||||
config_entry_id: str, camera_id: int
|
||||
) -> tuple[str, str, int]:
|
||||
) -> tuple[str, str]:
|
||||
"""Get the identifiers for a motionEye device."""
|
||||
return (DOMAIN, config_entry_id, camera_id)
|
||||
return (DOMAIN, f"{config_entry_id}_{camera_id}")
|
||||
|
||||
|
||||
def get_motioneye_entity_unique_id(
|
||||
|
|
|
@ -18,7 +18,7 @@ TEST_URL = f"http://test:{DEFAULT_PORT+1}"
|
|||
TEST_CAMERA_ID = 100
|
||||
TEST_CAMERA_NAME = "Test Camera"
|
||||
TEST_CAMERA_ENTITY_ID = "camera.test_camera"
|
||||
TEST_CAMERA_DEVICE_IDENTIFIER = (DOMAIN, TEST_CONFIG_ENTRY_ID, TEST_CAMERA_ID)
|
||||
TEST_CAMERA_DEVICE_IDENTIFIER = (DOMAIN, f"{TEST_CONFIG_ENTRY_ID}_{TEST_CAMERA_ID}")
|
||||
TEST_CAMERA = {
|
||||
"show_frame_changes": False,
|
||||
"framerate": 25,
|
||||
|
|
Loading…
Add table
Reference in a new issue