1
0
Fork 0
mirror of https://github.com/classchartsapi/classcharts-api-js.git synced 2026-05-14 11:58:13 +00:00

fix: use .has instead of .get

This commit is contained in:
James Cook 2023-09-10 13:02:05 +01:00
parent 17549a4f24
commit ffe3e24bbd
2 changed files with 2 additions and 2 deletions

View file

@ -41,7 +41,7 @@ export class ParentClient extends BaseClient {
headers: headers,
credentials: undefined,
});
if (response.status != 302 || !response.headers.get("set-cookie")) {
if (response.status != 302 || !response.headers.has("set-cookie")) {
throw new Error(
"Unauthenticated: ClassCharts returned an error: " +
response.status +