slight refactoring of posts.display