From 800efb3a34a13c20718a8489cae6f9d87193ec8b Mon Sep 17 00:00:00 2001 From: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com> Date: Fri, 3 Jun 2022 09:16:07 +0100 Subject: [PATCH 1/6] ios: fix authentication (#722) * ios: fix authentication * Update apps/ios/Shared/ContentView.swift Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com> * remove doAuthenticate = false * remove lock button * moare fixos * whitespace * and more Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com> --- apps/ios/Shared/ContentView.swift | 31 +++++-------------------------- apps/ios/Shared/SimpleXApp.swift | 16 ++++++++++++---- 2 files changed, 17 insertions(+), 30 deletions(-) diff --git a/apps/ios/Shared/ContentView.swift b/apps/ios/Shared/ContentView.swift index bb5ab76aa..6a4f6ddcc 100644 --- a/apps/ios/Shared/ContentView.swift +++ b/apps/ios/Shared/ContentView.swift @@ -12,16 +12,16 @@ struct ContentView: View { @ObservedObject var alertManager = AlertManager.shared @ObservedObject var callController = CallController.shared @Binding var doAuthenticate: Bool - @Binding var enteredBackground: Double? @State private var userAuthorized: Bool? - @State private var laFailed: Bool = false @AppStorage(DEFAULT_SHOW_LA_NOTICE) private var prefShowLANotice = false @AppStorage(DEFAULT_LA_NOTICE_SHOWN) private var prefLANoticeShown = false @AppStorage(DEFAULT_PERFORM_LA) private var prefPerformLA = false var body: some View { ZStack { - if userAuthorized == true { + if prefPerformLA && userAuthorized != true { + Button(action: runAuthenticate) { Label("Unlock", systemImage: "lock") } + } else { if let step = chatModel.onboardingStage { if case .onboardingComplete = step, let user = chatModel.currentUser { @@ -47,25 +47,13 @@ struct ContentView: View { OnboardingView(onboarding: step) } } - } else if prefPerformLA && laFailed { - retryAuthView() - } - } - .onChange(of: doAuthenticate) { doAuth in - if doAuth, authenticationExpired() { - runAuthenticate() } } + .onAppear { if doAuthenticate { runAuthenticate() } } + .onChange(of: doAuthenticate) { _ in if doAuthenticate { runAuthenticate() } } .alert(isPresented: $alertManager.presentAlert) { alertManager.alertView! } } - private func retryAuthView() -> some View { - Button { - laFailed = false - runAuthenticate() - } label: { Label("Retry", systemImage: "arrow.counterclockwise") } - } - private func runAuthenticate() { if !prefPerformLA { userAuthorized = true @@ -78,7 +66,6 @@ struct ContentView: View { case .success: userAuthorized = true case .failed: - laFailed = true AlertManager.shared.showAlert(laFailedAlert()) case .unavailable: userAuthorized = true @@ -90,14 +77,6 @@ struct ContentView: View { } } - private func authenticationExpired() -> Bool { - if let enteredBackground = enteredBackground { - return ProcessInfo.processInfo.systemUptime - enteredBackground >= 30 - } else { - return true - } - } - func laNoticeAlert() -> Alert { Alert( title: Text("SimpleX Lock"), diff --git a/apps/ios/Shared/SimpleXApp.swift b/apps/ios/Shared/SimpleXApp.swift index e1a54748b..0aad18a3e 100644 --- a/apps/ios/Shared/SimpleXApp.swift +++ b/apps/ios/Shared/SimpleXApp.swift @@ -17,8 +17,8 @@ struct SimpleXApp: App { @ObservedObject var alertManager = AlertManager.shared @Environment(\.scenePhase) var scenePhase @AppStorage(DEFAULT_PERFORM_LA) private var prefPerformLA = false - @State private var userAuthorized: Bool? = nil - @State private var doAuthenticate: Bool = false + @State private var userAuthorized: Bool? + @State private var doAuthenticate = false @State private var enteredBackground: Double? = nil init() { @@ -30,7 +30,7 @@ struct SimpleXApp: App { var body: some Scene { return WindowGroup { - ContentView(doAuthenticate: $doAuthenticate, enteredBackground: $enteredBackground) + ContentView(doAuthenticate: $doAuthenticate) .environmentObject(chatModel) .onOpenURL { url in logger.debug("ContentView.onOpenURL: \(url)") @@ -48,11 +48,19 @@ struct SimpleXApp: App { doAuthenticate = false enteredBackground = ProcessInfo.processInfo.systemUptime case .active: - doAuthenticate = true + doAuthenticate = authenticationExpired() default: break } } } } + + private func authenticationExpired() -> Bool { + if let enteredBackground = enteredBackground { + return ProcessInfo.processInfo.systemUptime - enteredBackground >= 30 + } else { + return true + } + } } From 3b708105a42d13192e51d8a4f9265ac2a66ca825 Mon Sep 17 00:00:00 2001 From: JRoberts <8711996+jr-simplex@users.noreply.github.com> Date: Fri, 3 Jun 2022 13:19:41 +0400 Subject: [PATCH 2/6] ios: fix modal views not closing (#723) --- apps/ios/Shared/ContentView.swift | 31 +++++++++---------- apps/ios/Shared/Model/ChatModel.swift | 1 - apps/ios/Shared/Views/Chat/ChatInfoView.swift | 7 +++-- apps/ios/Shared/Views/Chat/ChatView.swift | 10 +++--- .../Views/ChatList/ChatListNavLink.swift | 10 +++--- .../Shared/Views/ChatList/ChatListView.swift | 10 +++--- 6 files changed, 36 insertions(+), 33 deletions(-) diff --git a/apps/ios/Shared/ContentView.swift b/apps/ios/Shared/ContentView.swift index 6a4f6ddcc..9206d44d1 100644 --- a/apps/ios/Shared/ContentView.swift +++ b/apps/ios/Shared/ContentView.swift @@ -13,6 +13,7 @@ struct ContentView: View { @ObservedObject var callController = CallController.shared @Binding var doAuthenticate: Bool @State private var userAuthorized: Bool? + @State private var showChatInfo: Bool = false // TODO comprehensively close modal views on authentication @AppStorage(DEFAULT_SHOW_LA_NOTICE) private var prefShowLANotice = false @AppStorage(DEFAULT_LA_NOTICE_SHOWN) private var prefLANoticeShown = false @AppStorage(DEFAULT_PERFORM_LA) private var prefPerformLA = false @@ -24,9 +25,9 @@ struct ContentView: View { } else { if let step = chatModel.onboardingStage { if case .onboardingComplete = step, - let user = chatModel.currentUser { + chatModel.currentUser != nil { ZStack(alignment: .top) { - ChatListView(user: user) + ChatListView(showChatInfo: $showChatInfo) .onAppear { NtfManager.shared.requestAuthorization(onDeny: { alertManager.showAlert(notificationAlert()) @@ -58,20 +59,18 @@ struct ContentView: View { if !prefPerformLA { userAuthorized = true } else { - chatModel.showChatInfo = false - DispatchQueue.main.async() { - userAuthorized = false - authenticate(reason: NSLocalizedString("Unlock", comment: "authentication reason")) { laResult in - switch (laResult) { - case .success: - userAuthorized = true - case .failed: - AlertManager.shared.showAlert(laFailedAlert()) - case .unavailable: - userAuthorized = true - prefPerformLA = false - AlertManager.shared.showAlert(laUnavailableTurningOffAlert()) - } + showChatInfo = false + userAuthorized = false + authenticate(reason: NSLocalizedString("Unlock", comment: "authentication reason")) { laResult in + switch (laResult) { + case .success: + userAuthorized = true + case .failed: + AlertManager.shared.showAlert(laFailedAlert()) + case .unavailable: + userAuthorized = true + prefPerformLA = false + AlertManager.shared.showAlert(laUnavailableTurningOffAlert()) } } } diff --git a/apps/ios/Shared/Model/ChatModel.swift b/apps/ios/Shared/Model/ChatModel.swift index ebb3f6731..4d4ae6ad9 100644 --- a/apps/ios/Shared/Model/ChatModel.swift +++ b/apps/ios/Shared/Model/ChatModel.swift @@ -14,7 +14,6 @@ import WebKit final class ChatModel: ObservableObject { @Published var onboardingStage: OnboardingStage? @Published var currentUser: User? - @Published var showChatInfo: Bool = false // TODO comprehensively close modal views on authentication // list of chat "previews" @Published var chats: [Chat] = [] // current chat diff --git a/apps/ios/Shared/Views/Chat/ChatInfoView.swift b/apps/ios/Shared/Views/Chat/ChatInfoView.swift index 18e253b89..b7bd7ef58 100644 --- a/apps/ios/Shared/Views/Chat/ChatInfoView.swift +++ b/apps/ios/Shared/Views/Chat/ChatInfoView.swift @@ -12,6 +12,7 @@ struct ChatInfoView: View { @EnvironmentObject var chatModel: ChatModel @ObservedObject var alertManager = AlertManager.shared @ObservedObject var chat: Chat + @Binding var showChatInfo: Bool @State var alert: ChatInfoViewAlert? = nil @State var deletingContact: Contact? @@ -98,7 +99,7 @@ struct ChatInfoView: View { try await apiDeleteChat(type: .direct, id: contact.apiId) DispatchQueue.main.async { chatModel.removeChat(contact.id) - chatModel.showChatInfo = false + showChatInfo = false } } catch let error { logger.error("ChatInfoView.deleteContactAlert apiDeleteChat error: \(error.localizedDescription)") @@ -117,7 +118,7 @@ struct ChatInfoView: View { Task { await clearChat(chat) DispatchQueue.main.async { - chatModel.showChatInfo = false + showChatInfo = false } } }, @@ -129,6 +130,6 @@ struct ChatInfoView: View { struct ChatInfoView_Previews: PreviewProvider { static var previews: some View { @State var showChatInfo = true - return ChatInfoView(chat: Chat(chatInfo: ChatInfo.sampleData.direct, chatItems: [])) + return ChatInfoView(chat: Chat(chatInfo: ChatInfo.sampleData.direct, chatItems: []), showChatInfo: $showChatInfo) } } diff --git a/apps/ios/Shared/Views/Chat/ChatView.swift b/apps/ios/Shared/Views/Chat/ChatView.swift index b93252b53..12aa30a50 100644 --- a/apps/ios/Shared/Views/Chat/ChatView.swift +++ b/apps/ios/Shared/Views/Chat/ChatView.swift @@ -15,6 +15,7 @@ struct ChatView: View { @Environment(\.colorScheme) var colorScheme @AppStorage(DEFAULT_EXPERIMENTAL_CALLS) private var enableCalls = false @ObservedObject var chat: Chat + @Binding var showChatInfo: Bool @State private var composeState = ComposeState() @State private var deletingItem: ChatItem? = nil @FocusState private var keyboardVisible: Bool @@ -97,12 +98,12 @@ struct ChatView: View { } ToolbarItem(placement: .principal) { Button { - chatModel.showChatInfo = true + showChatInfo = true } label: { ChatInfoToolbar(chat: chat) } - .sheet(isPresented: $chatModel.showChatInfo) { - ChatInfoView(chat: chat) + .sheet(isPresented: $showChatInfo) { + ChatInfoView(chat: chat, showChatInfo: $showChatInfo) } } ToolbarItem(placement: .navigationBarTrailing) { @@ -269,7 +270,8 @@ struct ChatView_Previews: PreviewProvider { ChatItem.getSample(8, .directSnd, .now, "👍👍👍👍"), ChatItem.getSample(9, .directSnd, .now, "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.") ] - return ChatView(chat: Chat(chatInfo: ChatInfo.sampleData.direct, chatItems: [])) + @State var showChatInfo = false + return ChatView(chat: Chat(chatInfo: ChatInfo.sampleData.direct, chatItems: []), showChatInfo: $showChatInfo) .environmentObject(chatModel) } } diff --git a/apps/ios/Shared/Views/ChatList/ChatListNavLink.swift b/apps/ios/Shared/Views/ChatList/ChatListNavLink.swift index f23d29583..c8344980f 100644 --- a/apps/ios/Shared/Views/ChatList/ChatListNavLink.swift +++ b/apps/ios/Shared/Views/ChatList/ChatListNavLink.swift @@ -11,6 +11,7 @@ import SwiftUI struct ChatListNavLink: View { @EnvironmentObject var chatModel: ChatModel @State var chat: Chat + @Binding var showChatInfo: Bool @State private var showContactRequestDialog = false var body: some View { @@ -27,7 +28,7 @@ struct ChatListNavLink: View { } private func chatView() -> some View { - ChatView(chat: chat) + ChatView(chat: chat, showChatInfo: $showChatInfo) .onAppear { do { let cInfo = chat.chatInfo @@ -278,19 +279,20 @@ struct ChatListNavLink: View { struct ChatListNavLink_Previews: PreviewProvider { static var previews: some View { @State var chatId: String? = "@1" + @State var showChatInfo = false return Group { ChatListNavLink(chat: Chat( chatInfo: ChatInfo.sampleData.direct, chatItems: [ChatItem.getSample(1, .directSnd, .now, "hello")] - )) + ), showChatInfo: $showChatInfo) ChatListNavLink(chat: Chat( chatInfo: ChatInfo.sampleData.direct, chatItems: [ChatItem.getSample(1, .directSnd, .now, "hello")] - )) + ), showChatInfo: $showChatInfo) ChatListNavLink(chat: Chat( chatInfo: ChatInfo.sampleData.contactRequest, chatItems: [] - )) + ), showChatInfo: $showChatInfo) } .previewLayout(.fixed(width: 360, height: 80)) } diff --git a/apps/ios/Shared/Views/ChatList/ChatListView.swift b/apps/ios/Shared/Views/ChatList/ChatListView.swift index 746763583..33078d210 100644 --- a/apps/ios/Shared/Views/ChatList/ChatListView.swift +++ b/apps/ios/Shared/Views/ChatList/ChatListView.swift @@ -10,18 +10,17 @@ import SwiftUI struct ChatListView: View { @EnvironmentObject var chatModel: ChatModel + @Binding var showChatInfo: Bool // not really used in this view @State private var showSettings = false @State private var searchText = "" @AppStorage(DEFAULT_PENDING_CONNECTIONS) private var pendingConnections = true - var user: User - var body: some View { let v = NavigationView { List { ForEach(filteredChats()) { chat in - ChatListNavLink(chat: chat) + ChatListNavLink(chat: chat, showChatInfo: $showChatInfo) .padding(.trailing, -16) } } @@ -92,10 +91,11 @@ struct ChatListView_Previews: PreviewProvider { ) ] + @State var showChatInfo = false return Group { - ChatListView(user: User.sampleData) + ChatListView(showChatInfo: $showChatInfo) .environmentObject(chatModel) - ChatListView(user: User.sampleData) + ChatListView(showChatInfo: $showChatInfo) .environmentObject(ChatModel()) } } From 72103949a743bdb47b73a1fdc90bc937fc426bc1 Mon Sep 17 00:00:00 2001 From: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com> Date: Fri, 3 Jun 2022 12:24:50 +0100 Subject: [PATCH 3/6] ios: fix purple warning on auth failure (#724) * ios: fix purple warning on auth failure * avoid showing chats * avoid flicker * fix exit * bg task * rename function * remove bg task --- apps/ios/Shared/ContentView.swift | 35 ++++++++++++++++++------------- apps/ios/Shared/SimpleXApp.swift | 8 +++++-- 2 files changed, 27 insertions(+), 16 deletions(-) diff --git a/apps/ios/Shared/ContentView.swift b/apps/ios/Shared/ContentView.swift index 9206d44d1..6af294778 100644 --- a/apps/ios/Shared/ContentView.swift +++ b/apps/ios/Shared/ContentView.swift @@ -12,7 +12,7 @@ struct ContentView: View { @ObservedObject var alertManager = AlertManager.shared @ObservedObject var callController = CallController.shared @Binding var doAuthenticate: Bool - @State private var userAuthorized: Bool? + @Binding var userAuthorized: Bool? @State private var showChatInfo: Bool = false // TODO comprehensively close modal views on authentication @AppStorage(DEFAULT_SHOW_LA_NOTICE) private var prefShowLANotice = false @AppStorage(DEFAULT_LA_NOTICE_SHOWN) private var prefLANoticeShown = false @@ -58,20 +58,27 @@ struct ContentView: View { private func runAuthenticate() { if !prefPerformLA { userAuthorized = true - } else { + } else if showChatInfo { showChatInfo = false - userAuthorized = false - authenticate(reason: NSLocalizedString("Unlock", comment: "authentication reason")) { laResult in - switch (laResult) { - case .success: - userAuthorized = true - case .failed: - AlertManager.shared.showAlert(laFailedAlert()) - case .unavailable: - userAuthorized = true - prefPerformLA = false - AlertManager.shared.showAlert(laUnavailableTurningOffAlert()) - } + DispatchQueue.main.async { + justAuthenticate() + } + } else { + justAuthenticate() + } + } + + private func justAuthenticate() { + authenticate(reason: NSLocalizedString("Unlock", comment: "authentication reason")) { laResult in + switch (laResult) { + case .success: + userAuthorized = true + case .failed: + AlertManager.shared.showAlert(laFailedAlert()) + case .unavailable: + userAuthorized = true + prefPerformLA = false + AlertManager.shared.showAlert(laUnavailableTurningOffAlert()) } } } diff --git a/apps/ios/Shared/SimpleXApp.swift b/apps/ios/Shared/SimpleXApp.swift index 0aad18a3e..730e0cecc 100644 --- a/apps/ios/Shared/SimpleXApp.swift +++ b/apps/ios/Shared/SimpleXApp.swift @@ -30,7 +30,7 @@ struct SimpleXApp: App { var body: some Scene { return WindowGroup { - ContentView(doAuthenticate: $doAuthenticate) + ContentView(doAuthenticate: $doAuthenticate, userAuthorized: $userAuthorized) .environmentObject(chatModel) .onOpenURL { url in logger.debug("ContentView.onOpenURL: \(url)") @@ -45,10 +45,14 @@ struct SimpleXApp: App { switch (phase) { case .background: BGManager.shared.schedule() + if userAuthorized == true { + enteredBackground = ProcessInfo.processInfo.systemUptime + } doAuthenticate = false - enteredBackground = ProcessInfo.processInfo.systemUptime + userAuthorized = false case .active: doAuthenticate = authenticationExpired() + if !doAuthenticate { userAuthorized = true } default: break } From 47ec4862016b4601a08b65d2aab11133003738e3 Mon Sep 17 00:00:00 2001 From: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com> Date: Fri, 3 Jun 2022 12:46:11 +0100 Subject: [PATCH 4/6] update version v2.2.1 (52) --- apps/ios/SimpleX.xcodeproj/project.pbxproj | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/ios/SimpleX.xcodeproj/project.pbxproj b/apps/ios/SimpleX.xcodeproj/project.pbxproj index 7727b7f39..12221f85a 100644 --- a/apps/ios/SimpleX.xcodeproj/project.pbxproj +++ b/apps/ios/SimpleX.xcodeproj/project.pbxproj @@ -966,7 +966,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX (iOS).entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 51; + CURRENT_PROJECT_VERSION = 52; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; ENABLE_PREVIEWS = YES; @@ -989,7 +989,7 @@ ); "LIBRARY_SEARCH_PATHS[sdk=iphoneos*]" = "$(PROJECT_DIR)/Libraries/ios"; "LIBRARY_SEARCH_PATHS[sdk=iphonesimulator*]" = "$(PROJECT_DIR)/Libraries/sim"; - MARKETING_VERSION = 2.2; + MARKETING_VERSION = 2.2.1; PRODUCT_BUNDLE_IDENTIFIER = chat.simplex.app; PRODUCT_NAME = SimpleX; SDKROOT = iphoneos; @@ -1009,7 +1009,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX (iOS).entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 51; + CURRENT_PROJECT_VERSION = 52; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; ENABLE_PREVIEWS = YES; @@ -1032,7 +1032,7 @@ ); "LIBRARY_SEARCH_PATHS[sdk=iphoneos*]" = "$(PROJECT_DIR)/Libraries/ios"; "LIBRARY_SEARCH_PATHS[sdk=iphonesimulator*]" = "$(PROJECT_DIR)/Libraries/sim"; - MARKETING_VERSION = 2.2; + MARKETING_VERSION = 2.2.1; PRODUCT_BUNDLE_IDENTIFIER = chat.simplex.app; PRODUCT_NAME = SimpleX; SDKROOT = iphoneos; @@ -1091,7 +1091,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX NSE/SimpleX NSE.entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 51; + CURRENT_PROJECT_VERSION = 52; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; GENERATE_INFOPLIST_FILE = YES; @@ -1112,7 +1112,7 @@ "$(inherited)", "$(PROJECT_DIR)/Libraries/sim", ); - MARKETING_VERSION = 2.2; + MARKETING_VERSION = 2.2.1; PRODUCT_BUNDLE_IDENTIFIER = "chat.simplex.app.SimpleX-NSE"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = iphoneos; @@ -1131,7 +1131,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX NSE/SimpleX NSE.entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 51; + CURRENT_PROJECT_VERSION = 52; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; GENERATE_INFOPLIST_FILE = YES; @@ -1152,7 +1152,7 @@ "$(inherited)", "$(PROJECT_DIR)/Libraries/sim", ); - MARKETING_VERSION = 2.2; + MARKETING_VERSION = 2.2.1; PRODUCT_BUNDLE_IDENTIFIER = "chat.simplex.app.SimpleX-NSE"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = iphoneos; From 084d1d09a549c84a6f81ee02e319a97542fb29df Mon Sep 17 00:00:00 2001 From: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com> Date: Fri, 3 Jun 2022 13:05:34 +0100 Subject: [PATCH 5/6] ios: fix closing chat info (#725) --- apps/ios/Shared/ContentView.swift | 1 + apps/ios/Shared/SimpleXApp.swift | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/apps/ios/Shared/ContentView.swift b/apps/ios/Shared/ContentView.swift index 6af294778..e1e3b808b 100644 --- a/apps/ios/Shared/ContentView.swift +++ b/apps/ios/Shared/ContentView.swift @@ -69,6 +69,7 @@ struct ContentView: View { } private func justAuthenticate() { + userAuthorized = false authenticate(reason: NSLocalizedString("Unlock", comment: "authentication reason")) { laResult in switch (laResult) { case .success: diff --git a/apps/ios/Shared/SimpleXApp.swift b/apps/ios/Shared/SimpleXApp.swift index 730e0cecc..f6e5b23c4 100644 --- a/apps/ios/Shared/SimpleXApp.swift +++ b/apps/ios/Shared/SimpleXApp.swift @@ -49,10 +49,8 @@ struct SimpleXApp: App { enteredBackground = ProcessInfo.processInfo.systemUptime } doAuthenticate = false - userAuthorized = false case .active: doAuthenticate = authenticationExpired() - if !doAuthenticate { userAuthorized = true } default: break } From 935c3987b3f49f6f1d8a6a02f6e2e1a6314280ac Mon Sep 17 00:00:00 2001 From: JRoberts <8711996+jr-simplex@users.noreply.github.com> Date: Fri, 3 Jun 2022 16:18:34 +0400 Subject: [PATCH 6/6] update version v2.2.1 (53) --- apps/ios/SimpleX.xcodeproj/project.pbxproj | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/ios/SimpleX.xcodeproj/project.pbxproj b/apps/ios/SimpleX.xcodeproj/project.pbxproj index 12221f85a..27c9e9c79 100644 --- a/apps/ios/SimpleX.xcodeproj/project.pbxproj +++ b/apps/ios/SimpleX.xcodeproj/project.pbxproj @@ -966,7 +966,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX (iOS).entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 52; + CURRENT_PROJECT_VERSION = 53; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; ENABLE_PREVIEWS = YES; @@ -1009,7 +1009,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX (iOS).entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 52; + CURRENT_PROJECT_VERSION = 53; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; ENABLE_PREVIEWS = YES; @@ -1091,7 +1091,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX NSE/SimpleX NSE.entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 52; + CURRENT_PROJECT_VERSION = 53; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; GENERATE_INFOPLIST_FILE = YES; @@ -1131,7 +1131,7 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = "SimpleX NSE/SimpleX NSE.entitlements"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 52; + CURRENT_PROJECT_VERSION = 53; DEVELOPMENT_TEAM = 5NN7GUYB6T; ENABLE_BITCODE = NO; GENERATE_INFOPLIST_FILE = YES;