Adding PostRepository interface and fixing a bug with loading posts.