Some enhancements to UI functionality

This commit is contained in:
riversedge
2026-02-04 18:57:18 -05:00
parent 39960f0961
commit 16f5af6435
9 changed files with 374 additions and 33 deletions
+4 -1
View File
@@ -18,7 +18,7 @@ export class LocalStorageProvider implements StorageProvider {
const filepath = path.join(this.audioDir, key);
await mkdir(path.dirname(filepath), { recursive: true });
await writeFile(filepath, data);
return `/audio/${key}`;
return key;
}
async getUrl(key: string, _expiresIn?: number): Promise<string> {
@@ -26,6 +26,9 @@ export class LocalStorageProvider implements StorageProvider {
}
getPublicUrl(key: string): string {
if (key.startsWith('/audio/')) {
return key;
}
return `/audio/${key}`;
}