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

Function pick

wxapp/qqpcmgr.js:52–58  ·  view source on GitHub ↗
(source = {}, keys = [])

Source from the content-addressed store, hash-verified

50}
51
52function pick(source = {}, keys = []) {
53 for (const key of keys) {
54 const value = source?.[key];
55 if (value !== undefined && value !== null && value !== "") return value;
56 }
57 return "";
58}
59
60function findLoginPayload(source) {
61 if (!source || typeof source !== "object") return null;

Callers 2

findLoginPayloadFunction · 0.85
normalizeProfileFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected