♻️ Refactor backend
This commit is contained in:
@ -5,7 +5,7 @@ export async function getAuthtoken(username, password) {
|
||||
const response = await axios.get(
|
||||
`${baseUrl}/authid?user=${username}&password=${password}&bundleid&appversion&osversion&pushid`
|
||||
);
|
||||
if (response.data == "") throw "Wrong username or password";
|
||||
if (response.data == "") throw "Wrong DSB username or password";
|
||||
return response.data;
|
||||
}
|
||||
|
||||
|
@ -28,9 +28,9 @@ export class Parser {
|
||||
const plans = [];
|
||||
for (const entry of data) {
|
||||
// Download the substitution plan
|
||||
const data = await this.fetchFile(entry.url);
|
||||
const file = await this.fetchFile(entry.url);
|
||||
// Parse the substitution plan
|
||||
const parsed = parseSubstitutionPlan(data);
|
||||
const parsed = parseSubstitutionPlan(file);
|
||||
plans.push(parsed);
|
||||
}
|
||||
// Create a new parse event
|
||||
|
Reference in New Issue
Block a user