Skip to content
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

fix(messaging, android): revert changes made to potential fix as it was causing ANR reports for users #12396

Merged
merged 2 commits into from
Feb 28, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
import android.util.Log;
import androidx.annotation.NonNull;
import com.google.firebase.messaging.RemoteMessage;
import io.flutter.FlutterInjector;
import io.flutter.embedding.engine.FlutterEngine;
import io.flutter.embedding.engine.FlutterShellArgs;
import io.flutter.embedding.engine.dart.DartExecutor;
Expand Down Expand Up @@ -139,7 +138,6 @@ public void startBackgroundIsolate() {
* handle does not resolve to a Dart callback then this method does nothing.
* </ul>
*/
@SuppressWarnings("ConstantConditions")
public void startBackgroundIsolate(long callbackHandle, FlutterShellArgs shellArgs) {
if (backgroundFlutterEngine != null) {
Log.e(TAG, "Background isolate already started.");
Expand Down Expand Up @@ -180,14 +178,6 @@ public void startBackgroundIsolate(long callbackHandle, FlutterShellArgs shellAr
DartExecutor executor = backgroundFlutterEngine.getDartExecutor();
initializeMethodChannel(executor);

if (appBundlePath == null) {
// appBundlePath is possibly "null", this will allow us to fallback to the alternative lookup method.
// See: https://github.com/firebase/flutterfire/issues/9345#issuecomment-1467601511
Log.w(
TAG,
"startBackgroundIsolate: 'appBundlePath' was null, using alternative lookup method.");
appBundlePath = FlutterInjector.instance().flutterLoader().findAppBundlePath();
}
DartCallback dartCallback =
new DartCallback(assets, appBundlePath, flutterCallback);

Expand Down