fixed a bug with sundays