General refactoring, and fixed bug in day events that only returned for one date