MCPcopy Create free account
hub / github.com/6dylan6/jdm / GetPtPin

Function GetPtPin

function/sendNotify.js:1080–1115  ·  view source on GitHub ↗
(text)

Source from the content-addressed store, hash-verified

1078}
1079
1080async function GetPtPin(text) {
1081 try {
1082 const TempList = text.split('- ');
1083 if (TempList.length > 1) {
1084 var strNickName = TempList[TempList.length - 1];
1085 var strPtPin = "";
1086 console.log(`捕获别名:` + strNickName);
1087 if (TempCK) {
1088 for (let j = 0; j < TempCK.length; j++) {
1089 if (TempCK[j].nickName == strNickName) {
1090 strPtPin = TempCK[j].pt_pin;
1091 break;
1092 }
1093 if (TempCK[j].pt_pin == strNickName) {
1094 strPtPin = TempCK[j].pt_pin;
1095 break;
1096 }
1097 }
1098 if (strPtPin) {
1099 console.log(`反查PtPin成功:` + strPtPin);
1100 return strPtPin;
1101 } else {
1102 console.log(`别名反查PtPin失败: 1.用户更改了别名 2.可能是新用户,别名缓存还没有。`);
1103 return strNickName;
1104 }
1105 }
1106 } else {
1107 console.log(`标题格式无法捕获别名...`);
1108 return "";
1109 }
1110 } catch (error) {
1111 console.error(error);
1112 return "";
1113 }
1114
1115}
1116
1117async function isLoginByX1a0He(cookie) {
1118 return new Promise((resolve) => {

Callers 1

sendNotifyFunction · 0.70

Calls 1

logMethod · 0.45

Tested by

no test coverage detected