Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GetStandingsByTeam returns null object #1

Closed
Krazh opened this issue Oct 23, 2021 · 7 comments
Closed

GetStandingsByTeam returns null object #1

Krazh opened this issue Oct 23, 2021 · 7 comments
Assignees
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@Krazh
Copy link

Krazh commented Oct 23, 2021

Method returns the correct number of objects, however they are devoid of data.

EG.
Chelsea (Id 49, season 2021) should return 2 objects, 1 for Premier League, 1 for Champions League. In the live demo on the dashboard this works fine and is full of data but the method returns two null objects.

@pietrodicaprio
Copy link
Member

Ciao,

thank you for pointing out this bug.
Should be fixed with 2030a05
Do you have any change of testing it before I publish the package on NuGet? Otherwise I'll just publish it

@pietrodicaprio pietrodicaprio added the good first issue Good for newcomers label Oct 23, 2021
@Krazh
Copy link
Author

Krazh commented Oct 23, 2021

I'll check it out :)

@Krazh
Copy link
Author

Krazh commented Oct 23, 2021

On first glance at least, it works. I'll check it out more thoroughly later.

@Krazh
Copy link
Author

Krazh commented Oct 23, 2021

Is there a good reason you're wrapping the List inside another List in the League class? As far as I can see in the json it's only a single list.

@pietrodicaprio
Copy link
Member

image

unfortunately the JSON has as response property a list of objects.
The object has 1 property only: league
The league then has the standings property that (for unknown reasons) is a list of list where the first list always has 1 element.
I'll try to build a converter to skip the first list and have a cleaner navigation trough the object but first of all I want to be sure that the first list always contains 1 element only.

@Krazh
Copy link
Author

Krazh commented Oct 23, 2021

Ah right of course. I missed that. I'll just work around it for now :) they did a lot of that in v2 as well, I thought they'd stopped that. Thank you

@pietrodicaprio
Copy link
Member

Thank you for your support!
I'm going to close the issues and publish the package within today.
I'm here in anything comes up

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants