AI Image and Audio Generation Improvements.

AI Video Generation Pre-Flight Checklist. Cost Estimate Improvements.
This commit is contained in:
ajaysi committed 2025-12-25 16:26:08 +05:30
1 parent 59913bffa9
commit 7512933c65
163 files changed
+8938 -37401

No files matched your search

+3 -1
View File
@@ -9,7 +9,9 @@ export const setMediaAuthTokenGetter = (getter: (() => Promise<string | null>) |
export async function fetchMediaBlobUrl(pathOrUrl: string): Promise<string | null> {
try {
const rel = pathOrUrl.startsWith("/") ? pathOrUrl : `/${pathOrUrl}`;
// If full URL (http/https), use as-is; otherwise ensure leading slash
const isAbsolute = /^https?:\/\//i.test(pathOrUrl);
const rel = isAbsolute ? pathOrUrl : pathOrUrl.startsWith("/") ? pathOrUrl : `/${pathOrUrl}`;
// Try to get token and add as query parameter as fallback for endpoints that support it
// This helps with endpoints that use get_current_user_with_query_token