Fix wrong index offset

This commit is contained in:
EVAST9919 2017-11-07 14:30:44 +03:00
parent 8e806cd11c
commit 13cc1fcc92
1 changed files with 1 additions and 0 deletions

View File

@ -87,6 +87,7 @@ private void updateRankTexts()
private void showHistoryRankTexts(int dayIndex) private void showHistoryRankTexts(int dayIndex)
{ {
rankText.Text = $"#{ranks[dayIndex]:#,0}"; rankText.Text = $"#{ranks[dayIndex]:#,0}";
dayIndex++;
relativeText.Text = dayIndex == ranks.Length ? "Now" : $"{ranks.Length - dayIndex} days ago"; relativeText.Text = dayIndex == ranks.Length ? "Now" : $"{ranks.Length - dayIndex} days ago";
//plural should be handled in a general way //plural should be handled in a general way
} }