mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Switch to Xcode 14 and handle the UICollectionView-backed List. (#229)
* Fix Timeline on Xcode 14/iOS 16
Raise requirement to iOS 16+
Reduce pagination jumping.
Sonarcloud fixes.
Fix verification test.
Adopt if let optional { syntax.
* Remove unused ScrollViewReader
The ScrollViewReader didn't appear to change the behaviour.
* Fix warnings on Run Scripts.
Run script build phase 'SwiftLint' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking "Based on dependency analysis" in the script phase.
This commit is contained in:
@@ -21,7 +21,7 @@ import UIKit
|
||||
struct ServiceLocator {
|
||||
fileprivate static var serviceLocator: ServiceLocator?
|
||||
static var shared: ServiceLocator {
|
||||
guard let serviceLocator = serviceLocator else {
|
||||
guard let serviceLocator else {
|
||||
fatalError("The service locator should be setup at this point")
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ class AppCoordinator: Coordinator {
|
||||
private var userSession: UserSessionProtocol! {
|
||||
didSet {
|
||||
deobserveUserSessionChanges()
|
||||
if let userSession = userSession, !userSession.isSoftLogout {
|
||||
if let userSession, !userSession.isSoftLogout {
|
||||
observeUserSessionChanges()
|
||||
}
|
||||
}
|
||||
@@ -135,7 +135,7 @@ class AppCoordinator: Coordinator {
|
||||
// swiftlint:disable:next cyclomatic_complexity
|
||||
private func setupStateMachine() {
|
||||
stateMachine.addTransitionHandler { [weak self] context in
|
||||
guard let self = self else { return }
|
||||
guard let self else { return }
|
||||
|
||||
switch (context.fromState, context.event, context.toState) {
|
||||
case (.initial, .startWithAuthentication, .signedOut):
|
||||
@@ -297,7 +297,7 @@ class AppCoordinator: Coordinator {
|
||||
userSession.callbacks
|
||||
.receive(on: DispatchQueue.main)
|
||||
.sink { [weak self] callback in
|
||||
guard let self = self else { return }
|
||||
guard let self else { return }
|
||||
switch callback {
|
||||
case .didReceiveAuthError(let isSoftLogout):
|
||||
self.stateMachine.processEvent(.remoteSignOut(isSoft: isSoftLogout))
|
||||
|
||||
Reference in New Issue
Block a user