From 737fa75d284b932abb80b1bff0435e1f56fa83ec Mon Sep 17 00:00:00 2001 From: Luna712 <142361265+Luna712@users.noreply.github.com> Date: Sat, 28 Oct 2023 17:37:17 -0600 Subject: [PATCH] Fix --- .../lagradost/cloudstream3/utils/DataStoreHelper.kt | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/app/src/main/java/com/lagradost/cloudstream3/utils/DataStoreHelper.kt b/app/src/main/java/com/lagradost/cloudstream3/utils/DataStoreHelper.kt index 10a990ae..44a64855 100644 --- a/app/src/main/java/com/lagradost/cloudstream3/utils/DataStoreHelper.kt +++ b/app/src/main/java/com/lagradost/cloudstream3/utils/DataStoreHelper.kt @@ -245,13 +245,10 @@ object DataStoreHelper { if (currentEditAccount.lockPin != null) { // Ask for the current PIN showPinInputDialog(context, currentEditAccount.lockPin, false) { pin -> - if (pin == null || pin != currentEditAccount.lockPin) { - binding.lockProfileCheckbox.isChecked = true - } else { - // PIN is correct, proceed to update the account - performAccountUpdate(currentEditAccount) - dialog.dismissSafe() - } + if (pin == null) return@showPinInputDialog + // PIN is correct, proceed to update the account + performAccountUpdate(currentEditAccount) + dialog.dismissSafe() } } else { // No lock PIN set, proceed to update the account