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

Function firstValue

wxapp/ykb_all.js:200–206  ·  view source on GitHub ↗
(source = {}, keys = [])

Source from the content-addressed store, hash-verified

198}
199
200function firstValue(source = {}, keys = []) {
201 for (const key of keys) {
202 const value = source?.[key];
203 if (value !== undefined && value !== null && value !== "") return value;
204 }
205 return 0;
206}
207
208function isAuthError(e) {
209 return /token|登录|授权|非法请求|1500000004/i.test(String(e?.message || e || ""));

Callers 1

getAssetsMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected