Compatible with social model 2.0.0
This commit is contained in:
parent
cd5497507d
commit
3f7a9ae8a0
|
@ -34,7 +34,6 @@ public class CommentNotificationsThread implements Runnable {
|
|||
|
||||
/**
|
||||
*
|
||||
* @param libclient
|
||||
* @param userManager
|
||||
* @param commenterUserId
|
||||
* @param commentedPostId
|
||||
|
@ -44,7 +43,7 @@ public class CommentNotificationsThread implements Runnable {
|
|||
* @param commentKey
|
||||
* @param likes
|
||||
*/
|
||||
public CommentNotificationsThread(LibClient libclient, UserManager userManager, String commenterUserId,
|
||||
public CommentNotificationsThread(UserManager userManager, String commenterUserId,
|
||||
String commentedPostId, String commentText, NotificationsManager nm, String postOwnerId, String commentKey, ArrayList<Like> likes) {
|
||||
super();
|
||||
this.nm = nm;
|
||||
|
@ -55,14 +54,20 @@ public class CommentNotificationsThread implements Runnable {
|
|||
this.commentKey = commentKey;
|
||||
this.likes = likes;
|
||||
this.userManager = userManager;
|
||||
|
||||
try {
|
||||
LibClient libClient = new LibClient();
|
||||
userIdsToNotify = new HashSet<String>();
|
||||
List<Comment> postComments = libclient.getAllCommentsByPostIdLib(commentedPostId);
|
||||
List<Comment> postComments = libClient.getAllCommentsByPostIdLib(commentedPostId);
|
||||
for (Comment comment : postComments) {
|
||||
if (comment.getUserid().compareTo(commenterUserId) != 0) {
|
||||
userIdsToNotify.add(comment.getUserid());
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
|
||||
|
||||
|
||||
//clean
|
||||
//this.comments = comments;
|
||||
|
|
Loading…
Reference in New Issue