Extract method refactoringfor posts and topics