feat(useragent): bootstrap / unseal flow implementattion
This commit is contained in:
@@ -6,6 +6,7 @@ part 'bootstrap_token.g.dart';
|
||||
|
||||
@Riverpod(keepAlive: true)
|
||||
class BootstrapToken extends _$BootstrapToken {
|
||||
@override
|
||||
String? build() {
|
||||
return null;
|
||||
}
|
||||
@@ -14,9 +15,13 @@ class BootstrapToken extends _$BootstrapToken {
|
||||
state = token;
|
||||
}
|
||||
|
||||
void clear() {
|
||||
state = null;
|
||||
}
|
||||
|
||||
String? take() {
|
||||
final token = state;
|
||||
state = null;
|
||||
return token;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user