Created working get all posts CRUD function.