fix: improve dropbox loading resilience and fix dev proxy

This commit is contained in:
Christian Vidal Wolf
2026-04-22 16:09:00 +02:00
parent e7f88c67e6
commit eec500f737
2 changed files with 2 additions and 3 deletions
+1 -2
View File
@@ -25,8 +25,7 @@ export default async function handler(req, res) {
try { try {
accessToken = await getAccessToken(); accessToken = await getAccessToken();
} catch (err) { } catch (err) {
console.error('Token refresh error:', err); console.warn('Token refresh optional failure (sharing link might still work):', err.message);
return res.status(500).json({ error: err.message });
} }
if (req.method === 'GET' && req.query.info === '1') { if (req.method === 'GET' && req.query.info === '1') {
+1 -1
View File
@@ -21,7 +21,7 @@ export default defineConfig(({mode}) => {
hmr: process.env.DISABLE_HMR !== 'true', hmr: process.env.DISABLE_HMR !== 'true',
proxy: { proxy: {
'/dropbox-file': { '/dropbox-file': {
target: 'https://dl.dropboxusercontent.com', target: 'https://www.dropbox.com',
changeOrigin: true, changeOrigin: true,
rewrite: (path) => path.replace(/^\/dropbox-file/, ''), rewrite: (path) => path.replace(/^\/dropbox-file/, ''),
}, },