fix:登录退出页
This commit is contained in:
@@ -1,17 +1,33 @@
|
||||
import '../models/models.dart';
|
||||
|
||||
class AuthState {
|
||||
const AuthState({this.loggedIn = false, this.pendingAction});
|
||||
const AuthState({
|
||||
this.loggedIn = false,
|
||||
this.pendingAction,
|
||||
this.phone,
|
||||
this.loginMethod,
|
||||
});
|
||||
|
||||
final bool loggedIn;
|
||||
final PendingLoginAction? pendingAction;
|
||||
final String? phone;
|
||||
final LoginMethod? loginMethod;
|
||||
|
||||
AuthState copyWith({bool? loggedIn, Object? pendingAction = _sentinel}) {
|
||||
AuthState copyWith({
|
||||
bool? loggedIn,
|
||||
Object? pendingAction = _sentinel,
|
||||
Object? phone = _sentinel,
|
||||
Object? loginMethod = _sentinel,
|
||||
}) {
|
||||
return AuthState(
|
||||
loggedIn: loggedIn ?? this.loggedIn,
|
||||
pendingAction: identical(pendingAction, _sentinel)
|
||||
? this.pendingAction
|
||||
: pendingAction as PendingLoginAction?,
|
||||
phone: identical(phone, _sentinel) ? this.phone : phone as String?,
|
||||
loginMethod: identical(loginMethod, _sentinel)
|
||||
? this.loginMethod
|
||||
: loginMethod as LoginMethod?,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user