Refactor score table to leaderboard, update related models and services for consistency
LocationBasedServices/sumoc-backend/pipeline/head This commit looks good
LocationBasedServices/sumoc-backend/pipeline/head This commit looks good
This commit is contained in:
@@ -312,4 +312,15 @@ public class FriendshipService {
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
public List<User> getAcceptedFriends(User user) {
|
||||
List<Friendship> friendships = friendshipRepository.findByUserIdAndStatus(user.getId(), FriendShipStatus.ACCEPTED);
|
||||
List<User> friends = new ArrayList<>();
|
||||
|
||||
for (Friendship friendship : friendships) {
|
||||
friends.add(friendship.getFriend());
|
||||
}
|
||||
|
||||
return friends;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user