mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-22 15:51:12 -05:00
Fix: Add type field to submissions
This commit is contained in:
@@ -234,8 +234,14 @@ export async function fetchSubmissions(
|
|||||||
throw submissionsError;
|
throw submissionsError;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Enrich submissions with type field for UI conditional logic
|
||||||
|
const enrichedSubmissions = (submissions || []).map(sub => ({
|
||||||
|
...sub,
|
||||||
|
type: 'content_submission' as const,
|
||||||
|
}));
|
||||||
|
|
||||||
return {
|
return {
|
||||||
submissions: submissions || [],
|
submissions: enrichedSubmissions,
|
||||||
totalCount: count || 0,
|
totalCount: count || 0,
|
||||||
};
|
};
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|||||||
Reference in New Issue
Block a user