fix posts/comments resource class issue