1
0
Fork 0
mirror of https://github.com/classchartsapi/classcharts-api-js.git synced 2026-05-14 19:59:37 +00:00

Update parentClient.ts

Removed headers
This commit is contained in:
ChrisPhillips-cminion 2023-11-05 22:41:43 +00:00 committed by GitHub
parent 602529171f
commit 454e45d746
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -33,13 +33,10 @@ export class ParentClient extends BaseClient {
formData.append("logintype", "existing"); formData.append("logintype", "existing");
formData.append("password", this.password); formData.append("password", this.password);
formData.append("recaptcha-token", "no-token-available"); formData.append("recaptcha-token", "no-token-available");
const headers = new Headers({
"Content-Type": "application/x-www-form-urlencoded",
});
const response = await fetch(BASE_URL + "/parent/login", { const response = await fetch(BASE_URL + "/parent/login", {
method: "POST", method: "POST",
body: formData, body: formData,
headers: headers,
redirect: "manual", redirect: "manual",
}); });
if (response.status != 302 || !response.headers.has("set-cookie")) { if (response.status != 302 || !response.headers.has("set-cookie")) {