From 1d2ce5db7f6f2ac8fbeb2e2d0660dd2fe5cde55c Mon Sep 17 00:00:00 2001 From: LA-DI-DA <11174151+0O0o0oOoO00@users.noreply.github.com> Date: Tue, 19 Dec 2023 20:04:00 +0800 Subject: [PATCH] Fix: server key check for OTHERS_LOGIN_NOTIFY_SERVER --- module/device/device.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/module/device/device.py b/module/device/device.py index 293726b84..20cc14f4b 100644 --- a/module/device/device.py +++ b/module/device/device.py @@ -127,8 +127,9 @@ class Device(Screenshot, Control, AppControl, Platform): if deep_get(self.config.data, "OthersLogin.OthersLogin.Enable"): if OTHERS_LOGIN_CONFIRM.appear_on(self.image): - if OthersLoginNotifyOcr.ocr(self.image) == OTHERS_LOGIN_NOTIFY_SERVER[self.config.SERVER]: - raise OthersLogin + if self.config.SERVER in OTHERS_LOGIN_NOTIFY_SERVER.keys(): + if OthersLoginNotifyOcr.ocr(self.image) == OTHERS_LOGIN_NOTIFY_SERVER[self.config.SERVER]: + raise OthersLogin return self.image