Skip to content

Commit

Permalink
fix help text for questions
Browse files Browse the repository at this point in the history
  • Loading branch information
jochenklar committed Jun 21, 2016
1 parent fe5865f commit 47a99ab
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions apps/questions/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,14 @@ class Meta:
'attribute',
)

def to_representation(self, instance):
response = super(QuestionEntityQuestionSerializer, self).to_representation(instance)

if 'help' in response and response['help']:
response['help'] = markdown_function(force_text(response['help']))

return response


class QuestionEntitySerializer(serializers.ModelSerializer):

Expand Down

0 comments on commit 47a99ab

Please sign in to comment.