Start alarm service as non-foreground - 2.8 🚀

Closes #209
This commit is contained in:
Brandon Presley 2023-11-28 10:58:30 +13:00
parent 3ed87114d2
commit 8e9a6be85d
4 changed files with 6 additions and 6 deletions

View File

@ -85,8 +85,8 @@ android {
applicationId "com.massive"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 36222
versionName "2.7"
versionCode 36223
versionName "2.8"
}
signingConfigs {
release {

View File

@ -141,7 +141,7 @@ class AlarmModule constructor(context: ReactApplicationContext?) :
@RequiresApi(Build.VERSION_CODES.O)
override fun onFinish() {
val context = reactApplicationContext
context.startForegroundService(Intent(context, AlarmService::class.java))
context.startService(Intent(context, AlarmService::class.java))
context
.getJSModule(DeviceEventManagerModule.RCTDeviceEventEmitter::class.java)
.emit("tick", Arguments.createMap().apply {

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{
"name": "massive",
"version": "2.6",
"version": "2.7",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "massive",
"version": "2.6",
"version": "2.7",
"license": "GPL-3.0-only",
"dependencies": {
"@babel/plugin-proposal-class-properties": "^7.18.6",

View File

@ -1,6 +1,6 @@
{
"name": "massive",
"version": "2.7",
"version": "2.8",
"private": true,
"license": "GPL-3.0-only",
"scripts": {