restructuring. extracted functionality to helper methods in helpers.js
fixed bug in oneDayBlogs function. Can now use it effectively on both server and client