fixed no options
This commit is contained in:
@@ -54,10 +54,24 @@ function getCalendarEntries(weekDate) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function getUntis(weekDate) {
|
async function getUntis(weekDate) {
|
||||||
const untisSchools = process.env.UNTIS_SCHOOLS.split(",");
|
let untisSchools = [];
|
||||||
const untisUsernames = process.env.UNTIS_USERNAMES.split(",");
|
let untisUsernames = [];
|
||||||
const untisPasswords = process.env.UNTIS_PASSWORDS.split(",");
|
let untisPasswords = [];
|
||||||
const untisServers = process.env.UNTIS_SERVERS.split(",");
|
let untisServers = [];
|
||||||
|
|
||||||
|
let optionsSuccess = true;
|
||||||
|
try {
|
||||||
|
const untisSchools = process.env.UNTIS_SCHOOLS.split(",");
|
||||||
|
const untisUsernames = process.env.UNTIS_USERNAMES.split(",");
|
||||||
|
const untisPasswords = process.env.UNTIS_PASSWORDS.split(",");
|
||||||
|
const untisServers = process.env.UNTIS_SERVERS.split(",");
|
||||||
|
} catch (error) {
|
||||||
|
optionsSuccess = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!optionsSuccess) {
|
||||||
|
return "Keine Untis-Optionen gefunden";
|
||||||
|
}
|
||||||
|
|
||||||
let teachingContent = "";
|
let teachingContent = "";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user