feat(frontend): set default permanent API to jd-api.oiupoyt.space
This commit is contained in:
parent
0d78d9ac09
commit
3eaf9a659b
1 changed files with 5 additions and 1 deletions
|
|
@ -930,7 +930,11 @@
|
||||||
requestAnimationFrame(animateParticles);
|
requestAnimationFrame(animateParticles);
|
||||||
|
|
||||||
// ── API Configuration ────────────────────────────────────────────────────
|
// ── API Configuration ────────────────────────────────────────────────────
|
||||||
const DEFAULT_REMOTE_API = 'https://YOUR_BACKEND_URL.trycloudflare.com';
|
const DEFAULT_REMOTE_API = 'https://jd-api.oiupoyt.space';
|
||||||
|
const savedApi = localStorage.getItem('justdownload_api');
|
||||||
|
if (savedApi && (savedApi.includes('trycloudflare.com') || savedApi.includes('YOUR_BACKEND_URL'))) {
|
||||||
|
localStorage.removeItem('justdownload_api');
|
||||||
|
}
|
||||||
const urlParams = new URLSearchParams(window.location.search);
|
const urlParams = new URLSearchParams(window.location.search);
|
||||||
if (urlParams.has('api')) {
|
if (urlParams.has('api')) {
|
||||||
const customApi = urlParams.get('api').replace(/\/+$/, '');
|
const customApi = urlParams.get('api').replace(/\/+$/, '');
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue