Added delete post, bug fixes, general code refactor