Fixed a broken getPosts API and messed with the html