upload fix
Some checks are pending
CI Pipeline / Run Tests (push) Waiting to run
CI Pipeline / Lint Code (push) Waiting to run
CI Pipeline / Security Scan (push) Waiting to run
CI Pipeline / E2E Tests (push) Blocked by required conditions

This commit is contained in:
Enki 2025-08-27 21:16:48 -07:00
parent 4f4c817276
commit c57fea80eb

View File

@ -306,7 +306,10 @@ class GatewayUI {
// Set timeout (10 minutes for large files)
xhr.timeout = 600000;
// Set headers
// Open connection FIRST
xhr.open(options.method || 'GET', url);
// Set headers AFTER opening
Object.entries(options.headers || {}).forEach(([key, value]) => {
xhr.setRequestHeader(key, value);
});
@ -319,7 +322,6 @@ class GatewayUI {
}
// Send request
xhr.open(options.method || 'GET', url);
xhr.send(options.body);
});
}