Cleaned up some logic in date-containing views