mirror of
https://github.com/ZZZure/ZZZ-Plugin.git
synced 2025-12-16 13:17:32 +00:00
fix: uid
This commit is contained in:
parent
d02bfa9036
commit
08be225ffc
2 changed files with 9 additions and 8 deletions
|
|
@ -10,7 +10,7 @@ export const rulePrefix = '^((#|\\%)?(zzz|ZZZ|绝区零))';
|
|||
* @returns {Promise<Object>}
|
||||
*/
|
||||
export const getCk = async (e, s = false) => {
|
||||
e.isSr = true;
|
||||
e.isZZZ = true;
|
||||
let stoken = '';
|
||||
const user = new User(e);
|
||||
if (s) {
|
||||
|
|
@ -25,16 +25,18 @@ export const getCk = async (e, s = false) => {
|
|||
});
|
||||
return ck;
|
||||
}
|
||||
const mysUser = (await user.user()).getMysUser('zzz');
|
||||
const mysUser = await user.user();
|
||||
const zzzUser = mysUser.getMysUser('zzz');
|
||||
const uid = mysUser.getCkUid('zzz');
|
||||
let ck;
|
||||
if (mysUser) {
|
||||
if (zzzUser) {
|
||||
ck = {
|
||||
default: {
|
||||
ck: `${stoken}${mysUser.ck}`,
|
||||
uid: mysUser.getUid('zzz'),
|
||||
ck: `${stoken}${zzzUser.ck}`,
|
||||
uid: uid,
|
||||
qq: '',
|
||||
ltuid: mysUser.ltuid,
|
||||
device_id: mysUser.device,
|
||||
ltuid: zzzUser.ltuid,
|
||||
device_id: zzzUser.device,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,7 +50,6 @@ export class ZZZPlugin extends plugin {
|
|||
await this.reply('尚未绑定cookie,请先绑定cookie');
|
||||
return { api: null, uid: null, deviceFp: null };
|
||||
}
|
||||
|
||||
try {
|
||||
// 创建米游社 API 对象
|
||||
const api = new MysZZZApi(uid, ck);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue