MCPcopy Create free account
hub / github.com/smallfawn/QLScriptPublic / getAccounts

Function getAccounts

wxapp/ytb2_all.js:79–86  ·  view source on GitHub ↗
(app)

Source from the content-addressed store, hash-verified

77const unifiedEnv = parseUnifiedEnv();
78
79function getAccounts(app) {
80 const keys = [app.ck, app.appid, app.name].map((item) => item.toLowerCase());
81 const accounts = [];
82 if (unifiedEnv.global.length) accounts.push(...unifiedEnv.global);
83 for (const key of keys) accounts.push(...(unifiedEnv.byKey[key] || []));
84 accounts.push(...splitAccounts(process.env[app.ck] || ""));
85 return unique(accounts);
86}
87
88function maskPhone(phone = "") {
89 return String(phone).replace(/^(\d{3})\d{4}(\d{4})$/, "$1****$2");

Callers 1

ytb2_all.jsFile · 0.70

Calls 2

splitAccountsFunction · 0.70
uniqueFunction · 0.70

Tested by

no test coverage detected