File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
src/internal/activity-recognition/recognizers Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -70,7 +70,10 @@ export abstract class AndroidAbstractRecognizerManager
70
70
}
71
71
72
72
const pendingIntent = this . getPendingIntent ( ) ;
73
- const task = this . handleStop ( Utils . android . getApplicationContext ( ) , pendingIntent ) ;
73
+ const task = this . handleStop (
74
+ Utils . android . getApplicationContext ( ) ,
75
+ pendingIntent
76
+ ) ;
74
77
75
78
pendingIntent . cancel ( ) ;
76
79
this . pendingIntent = null ;
@@ -94,7 +97,9 @@ export abstract class AndroidAbstractRecognizerManager
94
97
Utils . android . getApplicationContext ( ) ,
95
98
0 ,
96
99
this . getReceiverIntent ( ) ,
97
- android . os . Build . VERSION . SDK_INT >= 23 ? PendingIntent . FLAG_NO_CREATE | PendingIntent . FLAG_IMMUTABLE : PendingIntent . FLAG_NO_CREATE
100
+ android . os . Build . VERSION . SDK_INT >= 31
101
+ ? PendingIntent . FLAG_NO_CREATE | PendingIntent . FLAG_MUTABLE
102
+ : PendingIntent . FLAG_NO_CREATE
98
103
) ;
99
104
return pendingIntent !== null ;
100
105
}
You can’t perform that action at this time.
0 commit comments