Skip to content

Commit 04732b4

Browse files
committed
🐛 Sync supabase DB types
1 parent 50b128e commit 04732b4

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

lib/supabase/repository.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ export const MUTATIONS = {
233233
translationId: string,
234234
name: string,
235235
) {
236-
return (supabase as any).rpc("update_translation", {
236+
return supabase.rpc("update_translation", {
237237
p_translation_id: translationId,
238238
p_name: name,
239239
});
@@ -243,7 +243,7 @@ export const MUTATIONS = {
243243
supabase: SupabaseClient<Database>,
244244
translationId: string,
245245
) {
246-
return (supabase as any).rpc("remove_translation", {
246+
return supabase.rpc("remove_translation", {
247247
p_translation_id: translationId,
248248
});
249249
},

lib/supabase/types.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -470,6 +470,10 @@ export type Database = {
470470
Args: { p_jargon_id: string }
471471
Returns: boolean
472472
}
473+
remove_translation: {
474+
Args: { p_translation_id: string }
475+
Returns: boolean
476+
}
473477
search_jargons: {
474478
Args: {
475479
category_acronyms?: string[]
@@ -565,6 +569,10 @@ export type Database = {
565569
jargon_slug: string
566570
}[]
567571
}
572+
update_translation: {
573+
Args: { p_name: string; p_translation_id: string }
574+
Returns: boolean
575+
}
568576
}
569577
Enums: {
570578
[_ in never]: never

0 commit comments

Comments
 (0)