Misc code cleanup
WIP, get posts by date.