Skip to content

Commit

Permalink
Update to latest Firebase and RxSwift
Browse files Browse the repository at this point in the history
  • Loading branch information
MrAsterisco committed Oct 11, 2021
1 parent 6820147 commit 094390d
Show file tree
Hide file tree
Showing 10 changed files with 158 additions and 158 deletions.
124 changes: 63 additions & 61 deletions Example/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4,61 +4,63 @@ PODS:
- AppAuth/ExternalUserAgent (= 1.4.0)
- AppAuth/Core (1.4.0)
- AppAuth/ExternalUserAgent (1.4.0)
- Firebase/Auth (7.1.0):
- Firebase/Auth (8.8.0):
- Firebase/CoreOnly
- FirebaseAuth (~> 7.1.0)
- Firebase/CoreOnly (7.1.0):
- FirebaseCore (= 7.1.0)
- FirebaseAuth (7.1.0):
- FirebaseCore (~> 7.0)
- GoogleUtilities/AppDelegateSwizzler (~> 7.0)
- GoogleUtilities/Environment (~> 7.0)
- GTMSessionFetcher/Core (~> 1.4)
- FirebaseCore (7.1.0):
- FirebaseCoreDiagnostics (~> 7.0)
- GoogleUtilities/Environment (~> 7.0)
- GoogleUtilities/Logger (~> 7.0)
- FirebaseCoreDiagnostics (7.1.0):
- GoogleDataTransport (~> 8.0)
- GoogleUtilities/Environment (~> 7.0)
- GoogleUtilities/Logger (~> 7.0)
- nanopb (~> 2.30906.0)
- GoogleDataTransport (8.0.1):
- nanopb (~> 2.30906.0)
- GoogleUtilities/AppDelegateSwizzler (7.1.1):
- FirebaseAuth (~> 8.8.0)
- Firebase/CoreOnly (8.8.0):
- FirebaseCore (= 8.8.0)
- FirebaseAuth (8.8.0):
- FirebaseCore (~> 8.0)
- GoogleUtilities/AppDelegateSwizzler (~> 7.4)
- GoogleUtilities/Environment (~> 7.4)
- GTMSessionFetcher/Core (~> 1.5)
- FirebaseCore (8.8.0):
- FirebaseCoreDiagnostics (~> 8.0)
- GoogleUtilities/Environment (~> 7.4)
- GoogleUtilities/Logger (~> 7.4)
- FirebaseCoreDiagnostics (8.8.0):
- GoogleDataTransport (~> 9.0)
- GoogleUtilities/Environment (~> 7.4)
- GoogleUtilities/Logger (~> 7.4)
- nanopb (~> 2.30908.0)
- GoogleDataTransport (9.1.0):
- GoogleUtilities/Environment (~> 7.2)
- nanopb (~> 2.30908.0)
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/AppDelegateSwizzler (7.5.2):
- GoogleUtilities/Environment
- GoogleUtilities/Logger
- GoogleUtilities/Network
- GoogleUtilities/Environment (7.1.1):
- PromisesObjC (~> 1.2)
- GoogleUtilities/Logger (7.1.1):
- GoogleUtilities/Environment (7.5.2):
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/Logger (7.5.2):
- GoogleUtilities/Environment
- GoogleUtilities/Network (7.1.1):
- GoogleUtilities/Network (7.5.2):
- GoogleUtilities/Logger
- "GoogleUtilities/NSData+zlib"
- GoogleUtilities/Reachability
- "GoogleUtilities/NSData+zlib (7.1.1)"
- GoogleUtilities/Reachability (7.1.1):
- "GoogleUtilities/NSData+zlib (7.5.2)"
- GoogleUtilities/Reachability (7.5.2):
- GoogleUtilities/Logger
- GTMSessionFetcher/Core (1.5.0)
- JWTDecode (2.5.0)
- nanopb (2.30906.0):
- nanopb/decode (= 2.30906.0)
- nanopb/encode (= 2.30906.0)
- nanopb/decode (2.30906.0)
- nanopb/encode (2.30906.0)
- PromisesObjC (1.2.11)
- RxCocoa (5.1.1):
- RxRelay (~> 5)
- RxSwift (~> 5)
- RxFireAuth (2.0.0):
- AppAuth (~> 1.4)
- Firebase/Auth (~> 7.1)
- JWTDecode (~> 2.5)
- RxCocoa (~> 5)
- RxRelay (5.1.1):
- RxSwift (~> 5)
- RxSwift (5.1.1)
- GTMSessionFetcher/Core (1.7.0)
- JWTDecode (2.6.3)
- nanopb (2.30908.0):
- nanopb/decode (= 2.30908.0)
- nanopb/encode (= 2.30908.0)
- nanopb/decode (2.30908.0)
- nanopb/encode (2.30908.0)
- PromisesObjC (2.0.0)
- RxCocoa (6.2.0):
- RxRelay (= 6.2.0)
- RxSwift (= 6.2.0)
- RxFireAuth (2.1.0):
- AppAuth (~> 1.0)
- Firebase/Auth (~> 8.0)
- JWTDecode (~> 2.0)
- RxCocoa (~> 6.0)
- RxRelay (6.2.0):
- RxSwift (= 6.2.0)
- RxSwift (6.2.0)

DEPENDENCIES:
- RxFireAuth (from `../`)
Expand Down Expand Up @@ -86,21 +88,21 @@ EXTERNAL SOURCES:

SPEC CHECKSUMS:
AppAuth: 31bcec809a638d7bd2f86ea8a52bd45f6e81e7c7
Firebase: 78e8dd2e39d653de6270432ad84fe8b59f7bf4e8
FirebaseAuth: f82c2cfcc1c107bb0a97735cdbce4eb2a601f710
FirebaseCore: 20046127eef0fcb8fa25df7fc12f7b97d4e48611
FirebaseCoreDiagnostics: 872cdb9b749b23346dddd5c1014d1babd2257de3
GoogleDataTransport: e4085e6762f36a6141738f46b0153473ce57fb18
GoogleUtilities: 3dc4ff0d5e4840e2fa8eef0889620e8c33d4218c
GTMSessionFetcher: b3503b20a988c4e20cc189aa798fd18220133f52
JWTDecode: d4c176a28a29f7e6f9abf5c90ad3002f69b98c7c
nanopb: 1bf24dd71191072e120b83dd02d08f3da0d65e53
PromisesObjC: 8c196f5a328c2cba3e74624585467a557dcb482f
RxCocoa: 32065309a38d29b5b0db858819b5bf9ef038b601
RxFireAuth: 28a2b31f9f9c8fdb82d8a7c45d282205db9e5471
RxRelay: d77f7d771495f43c556cbc43eebd1bb54d01e8e9
RxSwift: 81470a2074fa8780320ea5fe4102807cb7118178
Firebase: 629510f1a9ddb235f3a7c5c8ceb23ba887f0f814
FirebaseAuth: bcf0adeff88bda5dcb3beeabe5760f1226ab7b2f
FirebaseCore: 98b29e3828f0a53651c363937a7f7d92a19f1ba2
FirebaseCoreDiagnostics: fe77f42da6329d6d83d21fd9d621a6b704413bfc
GoogleDataTransport: 85fd18ff3019bb85d3f2c551d04c481dedf71fc9
GoogleUtilities: 8de2a97a17e15b6b98e38e8770e2d129a57c0040
GTMSessionFetcher: 43748f93435c2aa068b1cbe39655aaf600652e91
JWTDecode: 33e5e26e5ddbd21b2065820894c08fef0cad9509
nanopb: a0ba3315591a9ae0a16a309ee504766e90db0c96
PromisesObjC: 68159ce6952d93e17b2dfe273b8c40907db5ba58
RxCocoa: 4baf94bb35f2c0ab31bc0cb9f1900155f646ba42
RxFireAuth: 16c9dd96f9da2a915155cde5b44869fa8278a140
RxRelay: e72dbfd157807478401ef1982e1c61c945c94b2f
RxSwift: d356ab7bee873611322f134c5f9ef379fa183d8f

PODFILE CHECKSUM: ea8f92f08b272f64f10836eef47c81b25232df3f

COCOAPODS: 1.10.1
COCOAPODS: 1.10.2
24 changes: 12 additions & 12 deletions Example/RxFireAuth macOS/ViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class ViewController: NSViewController {
self.toggleProgress(false)

self.userManager.autoupdatingUser
.observeOn(MainScheduler.instance)
.observe(on: MainScheduler.instance)
.subscribe(onNext: { [unowned self] (user) in
if let user = user {
if user.isAnonymous {
Expand Down Expand Up @@ -88,7 +88,7 @@ class ViewController: NSViewController {
self.userManager.accessToken
}
.asObservable()
.observeOn(MainScheduler.instance)
.observe(on: MainScheduler.instance)
.map { $0 != nil ? $0 : "No access token." }
.bind(to: self.accessTokenLabel.rx.text)
.disposed(by: disposeBag)
Expand Down Expand Up @@ -135,7 +135,7 @@ class ViewController: NSViewController {
self.userManager.login(email: self.loginField.stringValue, password: self.passwordField.stringValue, allowMigration: self.migrationAllowance)
.subscribe(onSuccess: { [unowned self] in
self.handleLoggedIn($0)
}, onError: { [unowned self] in
}, onFailure: { [unowned self] in
self.handleSignInError(error: $0)
})
.disposed(by: self.disposeBag)
Expand All @@ -147,7 +147,7 @@ class ViewController: NSViewController {
self.userManager.signInWithApple(in: self, updateUserDisplayName: true, allowMigration: self.migrationAllowance)
.subscribe(onSuccess: { [unowned self] in
self.handleLoggedIn($0)
}, onError: { [unowned self] in
}, onFailure: { [unowned self] in
self.show(error: $0)
})
.disposed(by: self.disposeBag)
Expand All @@ -160,7 +160,7 @@ class ViewController: NSViewController {
self.userManager.signInWithGoogle(as: googleClientId, in: self, updateUserDisplayName: true, allowMigration: self.migrationAllowance)
.subscribe(onSuccess: { [unowned self] in
self.handleLoggedIn($0)
}, onError: { [unowned self] in
}, onFailure: { [unowned self] in
self.show(error: $0)
})
.disposed(by: self.disposeBag)
Expand Down Expand Up @@ -267,7 +267,7 @@ class ViewController: NSViewController {

self.toggleProgress(true)
self.userManager.confirmAuthentication(email: email, password: password)
.observeOn(MainScheduler.instance)
.observe(on: MainScheduler.instance)
.subscribe(onCompleted: { [unowned self] in
self.toggleProgress(false)
self.show(title: "Authentication Confirmed!", message: "You can now perform sensitive operations.")
Expand All @@ -279,7 +279,7 @@ class ViewController: NSViewController {
case .apple:
if #available(macOS 10.15, *) {
self.userManager.confirmAuthenticationWithApple(in: self)
.observeOn(MainScheduler.instance)
.observe(on: MainScheduler.instance)
.subscribe(onCompleted: { [unowned self] in
self.toggleProgress(false)
self.show(title: "Authentication Confirmed with Apple!", message: "You can now perform sensitive operations.")
Expand All @@ -293,7 +293,7 @@ class ViewController: NSViewController {

case .google:
self.userManager.confirmAuthenticationWithGoogle(as: self.googleClientId, in: self)
.observeOn(MainScheduler.instance)
.observe(on: MainScheduler.instance)
.subscribe(onCompleted: { [unowned self] in
self.toggleProgress(false)
self.show(title: "Authentication Confirmed with Google!", message: "You can now perform sensitive operations.")
Expand All @@ -320,7 +320,7 @@ class ViewController: NSViewController {
alert.beginSheetModal(for: view.window!) { [unowned self] (response) in
if response == .alertFirstButtonReturn {
self.userManager.confirmAuthentication(email: self.userManager.user!.email!, password: textField.stringValue)
.observeOn(MainScheduler.instance)
.observe(on: MainScheduler.instance)
.subscribe(onCompleted: { [unowned self] in
self.setNewPassword()
}, onError: { [unowned self] in
Expand All @@ -345,7 +345,7 @@ class ViewController: NSViewController {

alert.beginSheetModal(for: view.window!) { [unowned self] (response) in
self.userManager.updatePassword(newPassword: textField.stringValue)
.observeOn(MainScheduler.instance)
.observe(on: MainScheduler.instance)
.subscribe(onCompleted: { [unowned self] in
self.show(title: "Password set!", message: "Your new password has been set.")
}, onError: { [unowned self] in
Expand All @@ -366,11 +366,11 @@ class ViewController: NSViewController {
case .alertFirstButtonReturn:
if let credentials = credentials {
self.userManager.login(with: credentials, updateUserDisplayName: true, allowMigration: true)
.subscribe(onSuccess: self.handleLoggedIn(_:), onError: self.show(error:))
.subscribe(onSuccess: self.handleLoggedIn(_:), onFailure: self.show(error:))
.disposed(by: self.disposeBag)
} else {
self.userManager.login(email: self.loginField.stringValue, password: self.passwordField.stringValue, allowMigration: true)
.subscribe(onSuccess: self.handleLoggedIn(_:), onError: self.show(error:))
.subscribe(onSuccess: self.handleLoggedIn(_:), onFailure: self.show(error:))
.disposed(by: self.disposeBag)
}
default:
Expand Down
10 changes: 5 additions & 5 deletions Example/RxFireAuth.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 1200;
LastUpgradeCheck = 1200;
LastUpgradeCheck = 1300;
ORGANIZATIONNAME = CocoaPods;
TargetAttributes = {
607FACCF1AFB9204008FA782 = {
Expand Down Expand Up @@ -627,7 +627,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MACOSX_DEPLOYMENT_TARGET = 10.12;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
Expand Down Expand Up @@ -678,7 +678,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MACOSX_DEPLOYMENT_TARGET = 10.12;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
Expand All @@ -695,7 +695,7 @@
CODE_SIGN_ENTITLEMENTS = RxFireAuth/RxFireAuth_Example.entitlements;
DEVELOPMENT_TEAM = 43C9YP2S4Y;
INFOPLIST_FILE = RxFireAuth/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
"IPHONEOS_DEPLOYMENT_TARGET[sdk=macosx*]" = 14.2;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
MODULE_NAME = ExampleApp;
Expand All @@ -716,7 +716,7 @@
CODE_SIGN_ENTITLEMENTS = RxFireAuth/RxFireAuth_Example.entitlements;
DEVELOPMENT_TEAM = 43C9YP2S4Y;
INFOPLIST_FILE = RxFireAuth/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
"IPHONEOS_DEPLOYMENT_TARGET[sdk=macosx*]" = 14.2;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
MODULE_NAME = ExampleApp;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1200"
LastUpgradeVersion = "1300"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
Loading

0 comments on commit 094390d

Please sign in to comment.