added authorization checking with Pundit for posts