REFACTOR: isolate image uploading logic
Refactoring Task
Problem description
The codebase contains duplicate logic and linting errors for image uploads.
Affected Components/Files:
src/components/exhibition-editor.tsx
src/app/_components/create-exhibition-modal.tsx
-
src/utils/uploader.ts
? src/app/api/upload/route.ts
Tasks:
- Consolidate duplicate code regarding image uploads
- Fix linting errors regarding file uploads
- Fix any other code smells that are found in relating logic
Acceptance Criteria:
-
There is no duplicate code regarding image uploads -
Type and linting errors in uploading logic are fixed