Skip to content

Commit

Permalink
key passing value from info plist
Browse files Browse the repository at this point in the history
  • Loading branch information
cp-ishita-g committed Jul 19, 2024
1 parent 7929cff commit e07d5f1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/ios/Runner/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ import GoogleMaps
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
GMSServices.provideAPIKey("")
let key = Bundle.main.object(forInfoDictionaryKey: "ApiMapKey")
GMSServices.provideAPIKey(key as! String)
GeneratedPluginRegistrant.register(with: self)
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
}
Expand Down
2 changes: 2 additions & 0 deletions app/ios/Runner/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -70,5 +70,7 @@
<string>App requires permission to access photos</string>
<key>NSCameraUsageDescription</key>
<string>App requires permission to access camera</string>
<key>ApiMapKey</key>
<string>AIzaSyA8wfFT23_uHcL-5Jt_w1odqQA6yV3ZF60</string>
</dict>
</plist>

0 comments on commit e07d5f1

Please sign in to comment.