worked on database stuff for posts, there are errors