Skip to content

[firebase_auth] Add some info about method swizzling problem in iOS #286

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/firebase_auth/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.14.0+7

* Update README to show how to fix the method swizzling problem on iOS when call `verifyPhoneNumber`

## 0.14.0+6

* Update example app with correct const constructors.
Expand Down
8 changes: 7 additions & 1 deletion packages/firebase_auth/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,17 @@ After a successful authentication, you will receive a `FirebaseUser` object. You

- When testing you can add test phone numbers and verification codes to the Firebase console.

1. [Enable App verification](https://firebase.google.com/docs/auth/ios/phone-auth#enable-app-verification)
2. [Enable App verification](https://firebase.google.com/docs/auth/ios/phone-auth#enable-app-verification)

**Note:** App verification may use APNs, if using a simulator (where APNs does not work) or APNs is not setup on the
device you are using you must set the `URL Schemes` to the `REVERSE_CLIENT_ID` from the GoogleServices-Info.plist file.

**Known issue:** If you are trying to call `verifyPhoneNumber` and are receiving an `verifyPhoneNumberError` with the message

> If app delegate swizzling is disabled, remote notifications received by UIApplicationDelegate need to be forwarded to FIRAuth's canHandleNotificaton: method.

you should take a look at [this appendix on Firebase docs](https://firebase.google.com/docs/auth/ios/phone-auth#appendix:-using-phone-sign-in-without-swizzling). It'll require some changes in your iOS project.

#### Android setup

1. Enable Phone as a Sign-In method in the [Firebase console](https://console.firebase.google.com/u/0/project/_/authentication/providers)
Expand Down
2 changes: 1 addition & 1 deletion packages/firebase_auth/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: Flutter plugin for Firebase Auth, enabling Android and iOS
like Google, Facebook and Twitter.
author: Flutter Team <[email protected]>
homepage: https://github.com/FirebaseExtended/flutterfire/tree/master/packages/firebase_auth
version: 0.14.0+6
version: 0.14.0+7

flutter:
plugin:
Expand Down