2
0
mirror of https://github.com/ctrlcvs/xiaoyao-cvs-plugin.git synced 2025-01-22 13:51:10 +08:00

修正自动签到提示报错问题

This commit is contained in:
Ctrlcvs 2022-10-20 08:48:45 +08:00
parent eb2ba8c4e4
commit f685efd942

View File

@ -44,8 +44,8 @@ export async function cloudSign(e){
return true; return true;
} }
const checkAuth = async function (e) { const checkAuth = async function (e) {
if (!e.isMaster) { if (!e?.isMaster&&e?.reply) {
e.reply(`只有主人才能命令我哦~ e?.reply(`只有主人才能命令我哦~
(*/ω*)`) (*/ω*)`)
return false return false
} }
@ -53,7 +53,7 @@ const checkAuth = async function (e) {
} }
export async function signTask(e){ export async function signTask(e){
if (!await checkAuth(e)) { if (e&&!await checkAuth(e)) {
return true; return true;
} }
let user = new User(e); let user = new User(e);