Use dangerous util

This commit is contained in:
Eric Bailey
2025-01-07 16:48:04 -06:00
parent 61bf9291de
commit 2622c85bf2
@@ -66,6 +66,7 @@ import {ProfilesList} from '#/components/StarterPack/Main/ProfilesList'
import {QrCodeDialog} from '#/components/StarterPack/QrCodeDialog' import {QrCodeDialog} from '#/components/StarterPack/QrCodeDialog'
import {ShareDialog} from '#/components/StarterPack/ShareDialog' import {ShareDialog} from '#/components/StarterPack/ShareDialog'
import {Text} from '#/components/Typography' import {Text} from '#/components/Typography'
import * as atp from '#/types/atproto'
type StarterPackScreeProps = NativeStackScreenProps< type StarterPackScreeProps = NativeStackScreenProps<
CommonNavigatorParams, CommonNavigatorParams,
@@ -387,7 +388,12 @@ function Header({
}) })
} }
if (!AppBskyGraphStarterpack.isRecord(record)) { if (
!atp.dangerousIsType<AppBskyGraphStarterpack.Record>(
record,
AppBskyGraphStarterpack.isRecord,
)
) {
return null return null
} }