Parse StorageLimitExceededError while fetching upload URLs

This commit is contained in:
Vishnu Mohandas 2021-02-25 20:54:18 +05:30
parent fa2f40bc7a
commit 2659cb8ebc

View file

@ -435,6 +435,8 @@ class FileUploader {
} on DioError catch (e) {
if (e.response.statusCode == 402) {
throw NoActiveSubscriptionError();
} else if (e.response.statusCode == 426) {
throw StorageLimitExceededError();
}
throw e;
}