remove unused warnings, replace toDateMidnight with toDateTimeAtStartOfDay method as recommended by joda time lib.