mirror of
https://gitlab.dit.htwk-leipzig.de/htwk-software/htwkalender.git
synced 2025-07-23 13:08:48 +02:00
fix:#79 lint and format
This commit is contained in:
@ -6,12 +6,13 @@ export async function getCalender(token: string): Promise<Module[]> {
|
||||
method: "GET",
|
||||
});
|
||||
|
||||
return await fetch(request)
|
||||
.then((response) => {
|
||||
if( response.ok){
|
||||
return response.json().then((calendarResponse: Calendar) => calendarResponse.modules)
|
||||
} else {
|
||||
return [];
|
||||
}
|
||||
})
|
||||
return await fetch(request).then((response) => {
|
||||
if (response.ok) {
|
||||
return response
|
||||
.json()
|
||||
.then((calendarResponse: Calendar) => calendarResponse.modules);
|
||||
} else {
|
||||
return [];
|
||||
}
|
||||
});
|
||||
}
|
||||
|
Reference in New Issue
Block a user