Skip to content

Commit c1279cb

Browse files
committed
fix hardcoded exception
1 parent bb3beb6 commit c1279cb

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

templates/dart/lib/client.dart.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ class Client {
9898
}
9999
if(responseType == ResponseType.bytes) {
100100
final res = json.decode(utf8.decode(e.response.data));
101-
throw AppwriteException(res['message'],res['code'], res);
101+
throw {{spec.title | caseUcfirst}}Exception(res['message'],res['code'], res);
102102
}
103103
throw {{spec.title | caseUcfirst}}Exception(e.response.data['message'],e.response.data['code'], e.response.data);
104104
} catch(e) {

templates/flutter/lib/client.dart.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ class Client {
129129
}
130130
if(responseType == ResponseType.bytes) {
131131
final res = json.decode(utf8.decode(e.response.data));
132-
throw AppwriteException(res['message'],res['code'], res);
132+
throw {{spec.title | caseUcfirst}}Exception(res['message'],res['code'], res);
133133
}
134134
throw {{spec.title | caseUcfirst}}Exception(e.response.data['message'],e.response.data['code'], e.response.data);
135135
} catch(e) {

0 commit comments

Comments
 (0)