diff options
author | Evgeny Zinoviev <me@ch1p.io> | 2022-06-14 02:44:43 +0300 |
---|---|---|
committer | Evgeny Zinoviev <me@ch1p.io> | 2022-06-14 22:56:46 +0300 |
commit | e3d3d6b76010a6dd5c417f017339bec17fb07887 (patch) | |
tree | 42cb6194504ae863db2bf7d21ef9e2acd41d0fd2 /src/home/web_api | |
parent | 600fdf99ffd893857c9cdb9e68140766a963bd17 (diff) |
media: refactor sound_node, introduce camera_node
Diffstat (limited to 'src/home/web_api')
-rw-r--r-- | src/home/web_api/web_api.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/home/web_api/web_api.py b/src/home/web_api/web_api.py index c75c031..6b8c54e 100644 --- a/src/home/web_api/web_api.py +++ b/src/home/web_api/web_api.py @@ -12,7 +12,7 @@ from ..config import config, is_development_mode from ..database import BotsDatabase, SensorsDatabase from ..util import stringify, format_tb from ..api.types import BotType, TemperatureSensorLocation, SoundSensorLocation -from ..sound import RecordStorage +from ..media import SoundRecordStorage db: Optional[BotsDatabase] = None sensors_db: Optional[SensorsDatabase] = None @@ -136,7 +136,7 @@ def recordings_list(): if not os.path.isdir(root): raise ValueError(f'invalid node {node}: no such directory') - storage = RecordStorage(root) + storage = SoundRecordStorage(root) files = storage.getfiles(as_objects=extended) if extended: files = list(map(lambda file: file.__dict__(), files)) |