fix: show notification on error fetching marks #116
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { supabase } from '$lib/utils/functions/supabase';
|
||||
|
||||
export async function fetchMarks(courseId) {
|
||||
const { data } = await supabase.rpc('get_marks').eq('course_id', courseId);
|
||||
const { data, error } = await supabase.rpc('get_marks').eq('course_id', courseId);
|
||||
|
||||
return { data };
|
||||
return { data, error };
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user