| Index: chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationBuilderForO.java
|
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationBuilderForO.java b/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationBuilderForO.java
|
| index f442367066e1c0006d71c2df871fa4b01af6f9f2..7800aee5c21a0784d2513107d00a2f40b349ced7 100644
|
| --- a/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationBuilderForO.java
|
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationBuilderForO.java
|
| @@ -27,6 +27,11 @@ public class NotificationBuilderForO extends NotificationBuilder {
|
| ChannelsInitializer channelsInitializer) {
|
| super(context);
|
| assert BuildInfo.isAtLeastO();
|
| + if (channelId == null) {
|
| + // The channelId may be null if the notification will be posted by another app that
|
| + // does not target O or sets its own channels. E.g. Web apk notifications.
|
| + return;
|
| + }
|
| channelsInitializer.ensureInitialized(channelId);
|
| // TODO(crbug.com/707804) Stop using reflection once compileSdkVersion is high enough.
|
| try {
|
|
|