Skip to content

Commit

Permalink
fix(android-foreground-service): invalid property name returned on An…
Browse files Browse the repository at this point in the history
…droid (#164)
  • Loading branch information
robingenz committed Apr 29, 2024
1 parent 1e7c373 commit a9652e8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/new-adults-drop.md
@@ -0,0 +1,5 @@
---
'@capawesome-team/capacitor-android-foreground-service': patch
---

fix(android): invalid property name returned
Expand Up @@ -108,7 +108,7 @@ public void stopForegroundService(PluginCall call) {
public void checkPermissions(PluginCall call) {
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) {
JSObject result = new JSObject();
result.put("receive", "granted");
result.put(LOCAL_NOTIFICATIONS, "granted");
call.resolve(result);
} else {
super.checkPermissions(call);
Expand All @@ -120,7 +120,7 @@ public void checkPermissions(PluginCall call) {
public void requestPermissions(PluginCall call) {
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) {
JSObject result = new JSObject();
result.put("receive", "granted");
result.put(LOCAL_NOTIFICATIONS, "granted");
call.resolve(result);
} else {
if (getPermissionState(LOCAL_NOTIFICATIONS) == PermissionState.GRANTED) {
Expand Down

0 comments on commit a9652e8

Please sign in to comment.