Update Saqel Platform: 2026-09-08 23:44:33

This commit is contained in:
Hamza-Ayed
2026-09-08 23:44:33 +03:00
parent 41493f5dd6
commit be60f34148
3 changed files with 42 additions and 4 deletions
@@ -425,8 +425,9 @@ class TeacherRepository {
);
final decoded = json.decode(response.body) as Map<String, dynamic>;
if (response.statusCode == 200 || response.statusCode == 201)
if (response.statusCode == 200 || response.statusCode == 201 || response.statusCode == 422) {
return decoded;
}
throw StateError(
decoded['message']?.toString() ?? 'رفض الخادم رفع الحصة.');
} on StateError {