fixing bug that formats a two digit day or month number incorrectly