-
Notifications
You must be signed in to change notification settings - Fork 348
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
[Bug]: 0.19.3 Android: kotlin.UninitializedPropertyAccessException: lateinit property appEventsLogger has not been initialized #393
Comments
Hi @hhzhangzy have you tried put the line on some button and try try to click it? |
same here |
@joaoarmando could you put paste the code and show the files? |
didn't fix it for me |
This issue is stale because it has been open 7 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
same here. |
Update your style.xml file as below, maybe it will work <resources>
<string name="facebook_app_id">[APP_ID]</string>
<string name="facebook_client_token">[CLIENT_TOKEN]</string>
<string name="fb_login_protocol_scheme">fb[APP_ID]</string>
<string name="app_name">[APP_NAME]</string>
</resources> |
This issue is stale because it has been open 7 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
This issue was closed because it has been stalled for 5 days with no activity. |
Would you try the latest version v0.19.5 ? Please kindly confirm if the issue has been resolved. |
0.19.5 and I get the following error on my crashlytics:
|
Is there an existing issue for this?
Current Behavior
Install facebook_app_events: ^0.19.3 and configure Android manifest as documented with facebook_app_id and facebook_client_token
Call the ‘logPurchase‘ method
E/MethodChannel#flutter.oddbit.id/facebook_app_events( 2737): kotlin.UninitializedPropertyAccessException: lateinit property appEventsLogger has not been initialized.
Expected Behavior
Expected that the plugin would initialize the Facebook SDK
Steps To Reproduce
1.Install facebook_app_events: ^0.19.3[0.19.4, 0.19.2]
2. configure Android manifest as documented with facebook_app_id and facebook_client_token
<application android:label='xxxx'> <meta-data android:name="io.flutter.embedding.android.NormalTheme" android:resource="@style/NormalTheme" /> ... <meta-data android:name="com.facebook.sdk.ApplicationId" android:value="@string/facebook_app_id"/> <meta-data android:name="com.facebook.sdk.ClientToken" android:value="@string/facebook_client_token"/> </application >
, andriod/app/src/main/res/values and values-night/styles.xml
<resources> ... <style name="LaunchTheme" parent="@android:style/Theme.Black.NoTitleBar"> <!-- Show a splash screen on the activity. Automatically removed when the Flutter engine draws its first frame --> <item name="android:windowBackground">@drawable/launch_background</item> </style> ... <string name="facebook_app_id">xxx</string> // xxx representing the configured FaceBook AppId <string name="facebook_client_token">xxxxxxx</string> // xxxxxxx representing the configured FaceBook Token </resources>
Test in app:
FacebookAppEvents().logPurchase(amount: 1.00, currency: 'USD');
Platform
Android
Flutter Doctor
The text was updated successfully, but these errors were encountered: