hikvision: dynamic/digital channel support

This commit is contained in:
Koushik Dutta
2021-10-11 22:17:32 -07:00
parent d34c3964f3
commit f506a80f09
3 changed files with 4 additions and 4 deletions

View File

@@ -1,12 +1,12 @@
{
"name": "@scrypted/hikvision",
"version": "0.0.52",
"version": "0.0.53",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@scrypted/hikvision",
"version": "0.0.52",
"version": "0.0.53",
"license": "Apache",
"dependencies": {
"@mhoc/axios-digest-auth": "^0.7.0",

View File

@@ -1,6 +1,6 @@
{
"name": "@scrypted/hikvision",
"version": "0.0.52",
"version": "0.0.53",
"description": "HikVision Plugin for Scrypted",
"author": "Scrypted",
"license": "Apache",

View File

@@ -81,7 +81,7 @@ export class HikVisionCameraAPI {
this.console.log(data);
for (const event of Object.values(HikVisionCameraEvent)) {
if (data.indexOf(event) !== -1) {
const channel = data.match(/<channelID>(.*?)</)?.[1];
const channel = data.match(/<channelID>(.*?)</)?.[1] || data.match(/<dynChannelID>(.*?)</)?.[1];
if (this.channel
&& data.indexOf(`<channelID>${this.channel.substr(0, 1)}</channelID>`) === -1) {
continue;