- Store uploaded files as files/{ulid}/{original-name} instead of files/{ulid}/raw
- Store transcoded videos as {stem}-{resolution}.mp4 (e.g. foo-720p.mp4)
- Store transcoded images as {stem}-{width}p.webp (e.g. foo-1920p.webp)
- Add download?: boolean param to presign - only sets Content-Disposition: attachment when true
- Local storage handler only sets Content-Disposition when ?download=1 query param is present
- Add POST /api/files/download-url endpoint for key-based single file downloads
- Uses ResourceType.Asset for permission check
- Validates key belongs to the asset's storage directory
- Fix existing download-links API to pass download: true to presign
- Fix breadcrumb navbar download: video shows resolution submenu, others download directly
- Fix video player download: calls download-url API, shows correct file type label
- Remove filename query param hack from presign URLs
- Add sanitizeFilename() and stemFromKey() utility helpers
- Add key field to VideoTranscode DTO interface
When creating a version stack, the sortIndex was previously extracted
by taking files[0] from the database query result. Because findMany
without orderBy is non-deterministic, this resulted in flakiness
where the sortIndex would sometimes be null (from file2) instead of
'abc' (from file1), causing tests to fail.
We now look up the first file specifically based on the ordered
fileIds array parameter.
- Extracted recursive CTE cascade update to cascadeStatusToPendingPurge private helper
- Updated emptyTrash and expireTrashedAssets background job to use batch helper
- Added expireTrashedAssets GC test to verify date boundaries and recursive child marking
- Resolved typecast any warning in test
- Added emptyTrash method in AssetService to purge trashed assets from DB and S3
- Added POST /projects/:projectId/empty-trash endpoint in project API
- Implemented unit and integration tests for service and API
- Prevented double click redirect in recently deleted folder
- Added top banner with Delete Now option in recently-deleted folder with confirmation dialog