Fix up types in starter-packs queries

This commit is contained in:
Eric Bailey
2025-01-02 17:28:07 -06:00
parent 1e8823a507
commit 876ce4af7f
+5 -2
View File
@@ -131,7 +131,7 @@ export function useCreateStarterPackMutation({
return await agent.app.bsky.graph.starterpack.create(
{
repo: agent.session?.did,
repo: agent.session?.did!,
},
{
name,
@@ -366,7 +366,10 @@ export async function precacheStarterPack(
let starterPackView: AppBskyGraphDefs.StarterPackView | undefined
if (AppBskyGraphDefs.isStarterPackView(starterPack)) {
starterPackView = starterPack
} else if (AppBskyGraphDefs.isStarterPackViewBasic(starterPack)) {
} else if (
AppBskyGraphDefs.isStarterPackViewBasic(starterPack) &&
AppBskyGraphStarterpack.isValidRecord(starterPack.record)
) {
const listView: AppBskyGraphDefs.ListViewBasic = {
uri: starterPack.record.list,
// This will be populated once the data from server is fetched