(firstName: string | null, lastName: string | null)
| 39 | // The display name the seam reports: first + last, or nothing. Computed in SQL |
| 40 | // too (below) so the search term matches what the caller sees. |
| 41 | const displayName = (firstName: string | null, lastName: string | null): string | null => |
| 42 | [firstName, lastName].filter(Boolean).join(" ") || null; |
| 43 | |
| 44 | const makeService = (db: DrizzleDb): MemberDirectoryShape => { |
| 45 | const read = <A>(op: string, fn: () => Promise<A>) => |