Skip to content

Commit 4968e9a

Browse files
committed
Annotate instead of assert
1 parent f485ab0 commit 4968e9a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

com.unity.mobile.notifications/Runtime/Android/Plugins/com/unity/androidnotifications/UnityNotificationManager.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package com.unity.androidnotifications;
22

3+
import android.annotation.TargetApi;
34
import android.app.Activity;
45
import android.app.ActivityManager;
56
import android.app.AlarmManager;
@@ -233,9 +234,8 @@ protected static NotificationChannelWrapper getNotificationChannel(Context conte
233234
return channel;
234235
}
235236

237+
@TargetApi(Build.VERSION_CODES.O)
236238
protected static NotificationChannelWrapper notificationChannelToWrapper(NotificationChannel channel) {
237-
assert Build.VERSION.SDK_INT >= Build.VERSION_CODES.O;
238-
239239
NotificationChannelWrapper wrapper = new NotificationChannelWrapper();
240240

241241
wrapper.id = channel.getId();

0 commit comments

Comments
 (0)