unifi-protect: fix fingerprint on new protect

This commit is contained in:
Koushik Dutta
2024-11-13 19:01:57 -08:00
parent 4a51caa281
commit a8db883661
3 changed files with 5 additions and 4 deletions

View File

@@ -1,12 +1,12 @@
{
"name": "@scrypted/unifi-protect",
"version": "0.0.163",
"version": "0.0.164",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@scrypted/unifi-protect",
"version": "0.0.163",
"version": "0.0.164",
"license": "Apache",
"dependencies": {
"@koush/unifi-protect": "file:../../external/unifi-protect",

View File

@@ -1,6 +1,6 @@
{
"name": "@scrypted/unifi-protect",
"version": "0.0.163",
"version": "0.0.164",
"description": "Unifi Protect Plugin for Scrypted",
"author": "Scrypted",
"license": "Apache",

View File

@@ -221,7 +221,8 @@ export class UnifiProtect extends ScryptedDeviceBase implements Settings, Device
debounceMotionDetected(unifiCamera);
}
else if (payload.type === 'fingerprintIdentified') {
const userId: string = (payload as any).metadata?.fingerprint?.userId
const anypay = payload as any;
const userId: string = anypay.metadata?.fingerprint?.userId || anypay.metadata?.fingerprint?.ulpId;
if (userId) {
debounceFingerprintDetected(unifiCamera);
detections[0].label = userId;