refactoring and checkpoint
This commit is contained in:
@@ -27,3 +27,26 @@ class ServerExceptionWithMessage implements Exception {
|
||||
String toString() => 'ServerException: $message';
|
||||
}
|
||||
|
||||
class UserNotFoundException implements Exception {
|
||||
final String message;
|
||||
UserNotFoundException([this.message = "User not found"]);
|
||||
|
||||
@override
|
||||
String toString() => "UserNotFoundException: $message";
|
||||
}
|
||||
|
||||
class ConflictException implements Exception {
|
||||
final String message;
|
||||
ConflictException([this.message = "Conflict"]);
|
||||
|
||||
@override
|
||||
String toString() => "ConflictException: $message";
|
||||
}
|
||||
|
||||
class UnauthorizedException implements Exception {
|
||||
final String message;
|
||||
UnauthorizedException([this.message = "Unauthorized"]);
|
||||
|
||||
@override
|
||||
String toString() => "UnauthorizedException: $message";
|
||||
}
|
||||
Reference in New Issue
Block a user