MCPcopy Create free account
hub / github.com/block/buzz / getMockProfileByPubkey

Function getMockProfileByPubkey

desktop/src/testing/e2eBridge.ts:1789–1809  ·  view source on GitHub ↗
(pubkey: string)

Source from the content-addressed store, hash-verified

1787}
1788
1789function getMockProfileByPubkey(pubkey: string): RawProfile | null {
1790 const normalizedPubkey = pubkey.toLowerCase();
1791 const existing = mockProfiles.get(normalizedPubkey);
1792 if (existing) {
1793 return existing;
1794 }
1795
1796 if (!mockDisplayNames.has(normalizedPubkey)) {
1797 return null;
1798 }
1799
1800 return {
1801 pubkey: normalizedPubkey,
1802 display_name: mockDisplayNames.get(normalizedPubkey) ?? null,
1803 avatar_url: null,
1804 about: null,
1805 nip05_handle: null,
1806 owner_pubkey: null,
1807 is_agent: mockAgentPubkeys.has(normalizedPubkey),
1808 };
1809}
1810
1811function listMockProfiles(): RawProfile[] {
1812 const pubkeys = new Set<string>([

Callers 3

listMockProfilesFunction · 0.85
handleGetUserProfileFunction · 0.85
handleGetUsersBatchFunction · 0.85

Calls 2

hasMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected