feat: lint codebase and run precommit hook
This commit is contained in:
@@ -2,13 +2,7 @@
|
||||
* Server-side file type validation utilities for preventing malicious uploads
|
||||
* Specifically designed to prevent SVG XSS attacks and other security issues
|
||||
*/
|
||||
export const ALLOWED_IMAGE_TYPES = [
|
||||
'image/jpeg',
|
||||
'image/jpg',
|
||||
'image/png',
|
||||
'image/gif',
|
||||
'image/webp'
|
||||
] as const;
|
||||
export const ALLOWED_IMAGE_TYPES = ['image/jpeg', 'image/jpg', 'image/png', 'image/gif', 'image/webp'] as const;
|
||||
|
||||
export const ALLOWED_EXTENSIONS = ['.jpg', '.jpeg', '.png', '.gif', '.webp'] as const;
|
||||
|
||||
|
||||
@@ -24,11 +24,7 @@ export async function checkUserCoursePermissions(
|
||||
.single();
|
||||
|
||||
// Check if user is org admin
|
||||
const { data: orgData } = await supabase
|
||||
.from('group')
|
||||
.select('organization_id')
|
||||
.eq('id', courseGroupId)
|
||||
.single();
|
||||
const { data: orgData } = await supabase.from('group').select('organization_id').eq('id', courseGroupId).single();
|
||||
|
||||
let isOrgAdmin = false;
|
||||
if (orgData?.organization_id) {
|
||||
|
||||
Reference in New Issue
Block a user