adds Question case for commentable route

This commit is contained in:
Juanjo Bazán
2017-02-15 14:27:09 +01:00
parent 0a2c6c0921
commit c81b8550f0

View File

@@ -23,6 +23,8 @@ module CommentsHelper
def commentable_path(comment)
if comment.commentable_type == "Budget::Investment"
budget_investment_path(comment.commentable.budget_id, comment.commentable)
elsif comment.commentable_type == "Poll::Question"
question_path(comment.commentable)
else
comment.commentable
end