fix: comments were kinda ass

This commit is contained in:
2026-09-16 22:33:14 +02:00
parent f6d7c21691
commit 33d9ae11d8
9 changed files with 33 additions and 49 deletions
+1 -10
View File
@@ -40,7 +40,7 @@ class PinLockViewModel extends ChangeNotifier {
await load();
}
/// Checks whether a PIN has already been configured on this device.
// Checks whether a pin has already been configured on this device.
Future<void> load() async {
if (_isLoading) return;
@@ -66,9 +66,6 @@ class PinLockViewModel extends ChangeNotifier {
}
}
/// Creates a new PIN (first-time setup, or after disabling an old one).
/// Unlocks the app immediately on success, since the person just proved
/// they know it by typing it.
Future<bool> setPin(String pin) async {
_errorMessage = null;
@@ -94,7 +91,6 @@ class PinLockViewModel extends ChangeNotifier {
}
}
/// Checks an entered PIN against the stored one, unlocking on match.
Future<bool> verify(String pin) async {
_errorMessage = null;
@@ -118,7 +114,6 @@ class PinLockViewModel extends ChangeNotifier {
}
}
/// Replaces the current PIN. Requires the current PIN to match first.
Future<bool> changePin({
required String currentPin,
required String newPin,
@@ -134,7 +129,6 @@ class PinLockViewModel extends ChangeNotifier {
return setPin(newPin);
}
/// Removes the PIN entirely. Requires the current PIN to confirm.
Future<bool> disablePin(String currentPin) async {
final matches = await pinLockService.verifyPin(currentPin);
@@ -158,9 +152,6 @@ class PinLockViewModel extends ChangeNotifier {
return true;
}
/// Re-locks the app. Call this on app backgrounding (e.g. from a
/// WidgetsBindingObserver on AppLifecycleState.paused) if you want the
/// PIN required again after the app is put away, not just on cold start.
void lock() {
if (!_isUnlocked) return;