MCPcopy Create free account
hub / github.com/OpenRaiser/PaperFlow / sortedProfilePairs

Function sortedProfilePairs

deployments/desktop/static/desktop.js:4946–4953  ·  view source on GitHub ↗
(profile, raw, summaryKey, rawKey)

Source from the content-addressed store, hash-verified

4944 }
4945
4946 function sortedProfilePairs(profile, raw, summaryKey, rawKey) {
4947 const summaryItems = Array.isArray(profile?.[summaryKey]) ? profile[summaryKey] : [];
4948 if (summaryItems.length) return summaryItems.map(pairLabel).filter(Boolean);
4949 return Object.entries(raw?.[rawKey] || profile?.[rawKey] || {})
4950 .sort((a, b) => Number(b[1]) - Number(a[1]))
4951 .map(([key]) => key)
4952 .filter(Boolean);
4953 }
4954
4955 function profileMustReadValues(profile, raw) {
4956 const mustRead = raw?.must_read || profile?.must_read || {};

Callers 1

renderProfileFormFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected