Skip to content

LiveDataMapper followingCount and followers are in the wrong order #97

@lulajax

Description

@lulajax

In the LiveDataMapper class, there is a method public User getUser(JsonObject jsonElement). Within this method, a User object is being created with the following line:

var user = new User(id, name, profileName, picture, followers, followingCount, new ArrayList<>());

The issue is that the parameters followingCount and followers are in the wrong order. They need to be swapped to match the correct order expected by the User class constructor.

Here is the User constructor :

public User(Long id,
            String name,
            String profileName,
            Picture picture,
            long following,
            long followers,
            List<Badge> badges) {
    this.id = id;
    this.name = name;
    this.profileName = profileName;
    this.picture = picture;
    this.following = following;
    this.followers = followers;
    this.badges = badges;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions