This repository was archived by the owner on Aug 29, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -70,15 +70,17 @@ class _AuthenticatorWidgetState extends State<AuthenticatorWidget> {
70
70
late final StreamSubscription lockSubscription;
71
71
OverlayEntry ? overlayEntry;
72
72
bool _isShowingSplashScreen = true ;
73
+ late final Stream <LockState > lockState ;
73
74
74
75
@override
75
76
void initState () {
76
77
super .initState ();
78
+ lockState = widget.authenticator.lockState;
77
79
PinLock .setHideAppContent (
78
80
preference: widget.hideAppContent,
79
81
iosAssetImage: widget.iosImageAsset,
80
82
);
81
- lockSubscription = widget.authenticator. lockState.listen ((event) {
83
+ lockSubscription = lockState.listen ((event) {
82
84
if (event is Unlocked ) {
83
85
overlayEntry? .remove ();
84
86
overlayEntry = null ;
@@ -120,7 +122,7 @@ class _AuthenticatorWidgetState extends State<AuthenticatorWidget> {
120
122
@override
121
123
Widget build (BuildContext context) {
122
124
return StreamBuilder <LockState >(
123
- stream: widget.authenticator. lockState,
125
+ stream: lockState,
124
126
builder: (context, snapshot) {
125
127
if (snapshot.hasData && ! _isShowingSplashScreen) {
126
128
return widget.child;
You can’t perform that action at this time.
0 commit comments