Basic Webuntis error handling

This commit is contained in:
2023-03-31 21:24:38 +02:00
parent 4b9994a7ef
commit 9b6a307212
10 changed files with 148 additions and 153 deletions

View File

@ -11,7 +11,7 @@ class GetTimetableCache extends RequestCache<GetTimetableResponse> {
int startdate;
int enddate;
GetTimetableCache({required onUpdate, required this.startdate, required this.enddate}) : super(RequestCache.cacheMinute, onUpdate) {
GetTimetableCache({required onUpdate, onError, required this.startdate, required this.enddate}) : super(RequestCache.cacheMinute, onUpdate, onError: onError) {
start("MarianumMobile", "wu-timetable-$startdate-$enddate");
}

View File

@ -1,4 +1,4 @@
class WebuntisError {
class WebuntisError implements Exception {
String message;
int code;