From 5a2006538ae7b4000ac08145d3f4c92924b244bc Mon Sep 17 00:00:00 2001 From: Phillip Thelen Date: Tue, 11 Jun 2024 18:08:26 +0200 Subject: [PATCH] Fixes #1333 --- HabitRPG/UI/SetupViewController.swift | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/HabitRPG/UI/SetupViewController.swift b/HabitRPG/UI/SetupViewController.swift index 09762b5f2..cbfce6828 100644 --- a/HabitRPG/UI/SetupViewController.swift +++ b/HabitRPG/UI/SetupViewController.swift @@ -38,6 +38,7 @@ class SetupViewController: UIViewController, UIScrollViewDelegate { var createdTags = [SetupTaskCategory: TagProtocol]() var tagsToCreate = [SetupTaskCategory: TagProtocol]() + private var isCompletingSetup = false private let configRepository = ConfigRepository.shared @@ -186,7 +187,8 @@ class SetupViewController: UIViewController, UIScrollViewDelegate { } func completeSetup() { - if !tagsToCreate.isEmpty || !createdTags.isEmpty { + isCompletingSetup = true + if !tagsToCreate.isEmpty || !createdTags.isEmpty || isCompletingSetup { return } UserDefaults.standard.set(false, forKey: "isInSetup")