From f2c04476df9473fd0c56733c958a20c343c07dce Mon Sep 17 00:00:00 2001 From: k0shk0sh Date: Fri, 27 Dec 2019 22:40:34 +0100 Subject: [PATCH] fix double reaction --- .../com/fastaccess/provider/timeline/ReactionsProvider.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/fastaccess/provider/timeline/ReactionsProvider.java b/app/src/main/java/com/fastaccess/provider/timeline/ReactionsProvider.java index 7de56895..ab93b529 100644 --- a/app/src/main/java/com/fastaccess/provider/timeline/ReactionsProvider.java +++ b/app/src/main/java/com/fastaccess/provider/timeline/ReactionsProvider.java @@ -91,7 +91,7 @@ public class ReactionsProvider { return false; } ReactionTypes type = ReactionTypes.get(vId); - return type != null && type.getContent().equals(reactionsModel.getContent()); + return type != null && (type.getContent().equals(reactionsModel.getContent()) || type.getPostContent().equals(reactionsModel.getContent())); } public boolean isCallingApi(long id, int vId) { @@ -100,7 +100,8 @@ public class ReactionsProvider { return false; } ReactionTypes type = ReactionTypes.get(vId); - return type != null && type.getContent().equals(reactionsModel.getContent()) && reactionsModel.isCallingApi(); + return type != null && (type.getContent().equals(reactionsModel.getContent()) || type.getPostContent().equals(reactionsModel.getContent())) + && reactionsModel.isCallingApi(); } @NonNull private Map getReactionsMap() {