Skip to content

Commit 7bbaf82

Browse files
committed
Update Auth README to make more clear description #102
fix swift demo code (remove FB AppId and GGL Client Id params)
1 parent 0f5f836 commit 7bbaf82

File tree

2 files changed

+31
-37
lines changed

2 files changed

+31
-37
lines changed

samples/swift/uidemo/Info.plist

Lines changed: 29 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -24,54 +24,58 @@
2424
<key>CFBundleTypeRole</key>
2525
<string>Editor</string>
2626
<key>CFBundleURLName</key>
27-
<string>REVERSED_CLIENT_ID</string>
27+
<string></string>
2828
<key>CFBundleURLSchemes</key>
2929
<array>
30-
<string>REPLACE_ME_WITH_REVERSED_CLIENT_ID</string>
30+
<string>REVERSED_CLIENT_ID</string>
3131
</array>
3232
</dict>
3333
<dict>
3434
<key>CFBundleTypeRole</key>
3535
<string>Editor</string>
3636
<key>CFBundleURLName</key>
37-
<string>FACEBOOK_APP_ID</string>
37+
<string></string>
3838
<key>CFBundleURLSchemes</key>
3939
<array>
40-
<string>REPLACE_ME_WITH_FACEBOOK_APP_ID</string>
40+
<string>fb{your-app-id}</string>
4141
</array>
4242
</dict>
4343
<dict>
4444
<key>CFBundleTypeRole</key>
4545
<string>Editor</string>
4646
<key>CFBundleURLName</key>
47-
<string>TWITTER_CONSUMER_KEY</string>
47+
<string></string>
4848
<key>CFBundleURLSchemes</key>
4949
<array>
50-
<string>twitterkit-&lt;consumer_key&gt;</string>
50+
<string>twitterkit-{consumer-key}</string>
5151
</array>
5252
</dict>
5353
</array>
5454
<key>CFBundleVersion</key>
5555
<string>1</string>
56-
<key>Fabric</key>
57-
<dict>
58-
<key>APIKey</key>
59-
<string>FABRIC_API_KEY</string>
60-
<key>Kits</key>
61-
<array>
62-
<dict>
63-
<key>KitInfo</key>
64-
<dict>
65-
<key>consumerKey</key>
66-
<string>Consumer Key</string>
67-
<key>consumerSecret</key>
68-
<string>Consumer Secret</string>
69-
</dict>
70-
<key>KitName</key>
71-
<string>Twitter</string>
72-
</dict>
73-
</array>
74-
</dict>
56+
<key>FacebookAppID</key>
57+
<string>{your-app-id}</string>
58+
<key>FacebookDisplayName</key>
59+
<string>{your-app-name}</string>
60+
<key>Fabric</key>
61+
<dict>
62+
<key>APIKey</key>
63+
<string>FABRIC_API_KEY</string>
64+
<key>Kits</key>
65+
<array>
66+
<dict>
67+
<key>KitInfo</key>
68+
<dict>
69+
<key>consumerKey</key>
70+
<string>{consumer-key}</string>
71+
<key>consumerSecret</key>
72+
<string>{consumer-secret}</string>
73+
</dict>
74+
<key>KitName</key>
75+
<string>Twitter</string>
76+
</dict>
77+
</array>
78+
</dict>
7579
<key>LSApplicationQueriesSchemes</key>
7680
<array>
7781
<string>fbapi</string>

samples/swift/uidemo/Samples/Auth/FIRAuthViewController.swift

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,6 @@ import FirebaseTwitterAuthUI
2323

2424
let kFirebaseTermsOfService = NSURL(string: "https://firebase.google.com/terms/")!
2525

26-
// Your Google app's client ID, which can be found in the GoogleService-Info.plist file
27-
// and is stored in the `clientID` property of your FIRApp options.
28-
// Firebase Google auth is built on top of Google sign-in, so you'll have to add a URL
29-
// scheme to your project as outlined at the bottom of this reference:
30-
// https://developers.google.com/identity/sign-in/ios/start-integrating
31-
let kGoogleAppClientID = (FIRApp.defaultApp()?.options.clientID)!
32-
33-
// Your Facebook App ID, which can be found on developers.facebook.com.
34-
let kFacebookAppID = "your fb app ID here"
35-
3626
/// A view controller displaying a basic sign-in flow using FIRAuthUI.
3727
class FIRAuthViewController: UITableViewController {
3828
// Before running this sample, make sure you've correctly configured
@@ -64,8 +54,8 @@ class FIRAuthViewController: UITableViewController {
6454
// If you haven't set up your authentications correctly these buttons
6555
// will still appear in the UI, but they'll crash the app when tapped.
6656
let providers: [FIRAuthProviderUI] = [
67-
FIRGoogleAuthUI(clientID: kGoogleAppClientID),
68-
FIRFacebookAuthUI(appID: kFacebookAppID),
57+
FIRGoogleAuthUI(),
58+
FIRFacebookAuthUI(),
6959
FIRTwitterAuthUI(),
7060
]
7161
self.authUI?.providers = providers

0 commit comments

Comments
 (0)