From 600094e20ce7acb0a0ed10ffdd9085feb7010662 Mon Sep 17 00:00:00 2001 From: Nan Date: Sun, 10 Dec 2023 16:56:24 -0800 Subject: [PATCH] Android User bridge methods should resolve * A few methods were missing the `replySuccess` to resolve the call from the app developer. --- .../src/main/java/com/onesignal/flutter/OneSignalUser.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/android/src/main/java/com/onesignal/flutter/OneSignalUser.java b/android/src/main/java/com/onesignal/flutter/OneSignalUser.java index 4909a59..09d6f5e 100644 --- a/android/src/main/java/com/onesignal/flutter/OneSignalUser.java +++ b/android/src/main/java/com/onesignal/flutter/OneSignalUser.java @@ -58,6 +58,7 @@ private void setLanguage(MethodCall call, Result result) { language = null; } OneSignal.getUser().setLanguage(language); + replySuccess(result, null); } private void addAliases(MethodCall call, Result result) { @@ -65,6 +66,7 @@ private void addAliases(MethodCall call, Result result) { // a ClassCastException will be thrown try { OneSignal.getUser().addAliases((Map) call.arguments); + replySuccess(result, null); } catch(ClassCastException e) { replyError(result, "OneSignal", "addAliases failed with error: " + e.getMessage() + "\n" + e.getStackTrace(), null); } @@ -75,6 +77,7 @@ private void removeAliases(MethodCall call, Result result) { // a ClassCastException will be thrown try { OneSignal.getUser().removeAliases((List) call.arguments); + replySuccess(result, null); } catch(ClassCastException e) { replyError(result, "OneSignal", "removeAliases failed with error: " + e.getMessage() + "\n" + e.getStackTrace(), null); } @@ -105,6 +108,7 @@ private void addTags(MethodCall call, Result result) { // a ClassCastException will be thrown try { OneSignal.getUser().addTags((Map) call.arguments); + replySuccess(result, null); } catch(ClassCastException e) { replyError(result, "OneSignal", "addTags failed with error: " + e.getMessage() + "\n" + e.getStackTrace(), null); } @@ -115,6 +119,7 @@ private void removeTags(MethodCall call, Result result) { // a ClassCastException will be thrown try { OneSignal.getUser().removeTags((List) call.arguments); + replySuccess(result, null); } catch(ClassCastException e) { replyError(result, "OneSignal", "deleteTags failed with error: " + e.getMessage() + "\n" + e.getStackTrace(), null); }