thedevsaddam / bongo

Terminal based bengali calendar
14 stars 5 forks source link

Last line of the calendar will be missing for some months #2

Open me-shaon opened 6 years ago

me-shaon commented 6 years ago

It seems like you are fixing the number of rows of the calendar to 5. As the TotalRow calculations by the following code: totalRow := int(math.Ceil(float64(mnthTotalDys) / 7.0)) will always return 5, because mnthTotalDys value can be either 30 or 31. So, if the first day of the bangla month starts at 'friday' or 'saturday' then some of the last days will be in the 6th row, which will be stripped off. As a matter of fact, this will happen in the next month too.

me-shaon commented 6 years ago

Solved in PR #3
Accidentally pointed to the wrong Issue number in the PR commit.