Closed dragosperca closed 11 years ago
Even with a more 'normal', Sunday/Monday start, for September 2013, the class generates an empty week (see printscreen below) which suggests Month.php class should be changed a little.
@dragosperca Hi, could you open an other issue for second case ?
Fixed.
both patches seem to work great, thank you! Do you know when this change will be visible within Composer/Packagist?
I'll tag a new release, it should be available in minutes.
When calling $factory->setFirstWeekday() depending on current month first day, the class can generate an error.
For example, trying to set first week day as Thursday on May 2013, via: $factory->setFirstWeekday(4)
generates this: Fatal error: Uncaught exception 'Exception' with message 'DateInterval::__construct() [dateinterval.--construct]: Unknown or bad format (P-1D)' in ../vendor/yohang/calendr/src/CalendR/Period/Month.php:84