Skip to content

Commit d49f420

Browse files
committed
refactor: rename UserFailure.none to UserFailure.empty
1 parent 820b44c commit d49f420

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

lib/app/cubit/app_state.dart

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ final class AppState extends Equatable {
1818
const AppState._({
1919
required this.status,
2020
this.user = User.none,
21-
this.failure = UserFailure.none,
21+
this.failure = UserFailure.empty,
2222
});
2323

2424
const AppState.unauthenticated() : this._(status: AppStatus.unauthenticated);

lib/login/cubit/login_state.dart

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ final class LoginState extends Equatable {
1818
const LoginState._({
1919
this.status = LoginStatus.initial,
2020
this.signInMethod = SignInMethod.none,
21-
this.failure = UserFailure.none,
21+
this.failure = UserFailure.empty,
2222
});
2323

2424
const LoginState.initial() : this._();

packages/user_repository/lib/src/failures.dart

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ class UserFailure extends Failure {
1313
factory UserFailure.fromSignInWithAppleNotSupported() =>
1414
const AppleSignInNotSupportedFailure();
1515

16-
static const none = UserNoFailure();
16+
static const empty = EmptyUserFailure();
1717
}
1818

19-
class UserNoFailure extends UserFailure {
20-
const UserNoFailure() : super._();
19+
class EmptyUserFailure extends UserFailure {
20+
const EmptyUserFailure() : super._();
2121
}
2222

2323
class AuthUserChangesFailure extends UserFailure {

0 commit comments

Comments
 (0)