fix: Properly type Array.from() calls in ChannelListRenderer

Fixes TS2345 errors by explicitly typing the Array.from<NostrEvent>() calls
when converting Map iterator values to arrays. This resolves the 'unknown'
type inference issues in the map callbacks.
This commit is contained in:
Claude
2026-01-18 08:34:25 +00:00
parent 553008610b
commit 09812afff5

View File

@@ -110,7 +110,7 @@ export function ChannelListRenderer({ event }: BaseEventProps) {
const kind40Pubkeys = kind40Events
? Array.from(
new Set(
Array.from(kind40Events.values()).map((e: NostrEvent) => e.pubkey),
Array.from<NostrEvent>(kind40Events.values()).map((e) => e.pubkey),
),
)
: [];
@@ -253,7 +253,7 @@ export function ChannelListDetailRenderer({ event }: { event: NostrEvent }) {
const kind40Pubkeys = kind40Events
? Array.from(
new Set(
Array.from(kind40Events.values()).map((e: NostrEvent) => e.pubkey),
Array.from<NostrEvent>(kind40Events.values()).map((e) => e.pubkey),
),
)
: [];