MCPcopy Index your code
hub / github.com/callumalpass/tasknotes / buildCustomFrontmatter

Function buildCustomFrontmatter

src/modals/taskModalUserFields.ts:42–54  ·  view source on GitHub ↗
(
	userFields: Record<string, unknown>
)

Source from the content-addressed store, hash-verified

40}
41
42export function buildCustomFrontmatter(
43 userFields: Record<string, unknown>
44): Record<string, unknown> {
45 const customFrontmatter: Record<string, unknown> = {};
46
47 for (const [fieldKey, fieldValue] of Object.entries(userFields)) {
48 if (fieldValue !== null && fieldValue !== undefined && fieldValue !== "") {
49 customFrontmatter[fieldKey] = fieldValue;
50 }
51 }
52
53 return customFrontmatter;
54}
55
56export function getUserFieldChanges(
57 userFields: Record<string, unknown>,

Callers 2

buildTaskCreationDataFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected