bugfixing for "get first and last date with weekdays"