xamarin / Sport

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unhandled Exception on LeagueDetailsPage (resolution)

shainefisher opened this issue · comments

As I build with VS 2017 15.4.0 Pre 2.0 I am having some random issues, here is a solution to one of them. When you click on the League to go to the Detail page (either to join or just view) the app crashes with an Unhandled Exception, the issue is with the CarouselView, well the data source. If you get this issue then the solution is easy enough, change LeagueDetailsViewModel (line 105, 106) to:

if(OngoingChallengeViewModels == null)
    OngoingChallengeViewModels = new ObservableCollection<ChallengeDetailsViewModel>() { **new ChallengeDetailsViewModel()** };

Solves the issue, and doesn't seem to have any major side effects.

Closing as resolved, so the queue doesn't look horribly long.