diff options
-rw-r--r-- | askbot/models/signals.py | 3 | ||||
-rw-r--r-- | askbot/views/writers.py | 14 |
2 files changed, 7 insertions, 10 deletions
diff --git a/askbot/models/signals.py b/askbot/models/signals.py index 303db2a2..4104ec62 100644 --- a/askbot/models/signals.py +++ b/askbot/models/signals.py @@ -34,9 +34,6 @@ new_question_posted = django.dispatch.Signal( answer_edited = django.dispatch.Signal( providing_args=['answer', 'user', 'form_data'] ) -answer_before_editing = django.dispatch.Signal( - providing_args=['answer', 'user', 'form'] -) post_updated = django.dispatch.Signal( providing_args=[ diff --git a/askbot/views/writers.py b/askbot/views/writers.py index bec059ef..fb1742f6 100644 --- a/askbot/views/writers.py +++ b/askbot/views/writers.py @@ -551,13 +551,6 @@ def edit_answer(request, id): if request.user.can_make_group_private_posts(): form.initial['post_privately'] = answer.is_private() - #gives a chance to set extra initial data on the form - signals.answer_before_editing.send(None, - answer=answer, - user=request.user, - form=form - ) - data = { 'page_class': 'edit-answer-page', 'active_tab': 'questions', @@ -566,6 +559,13 @@ def edit_answer(request, id): 'revision_form': revision_form, 'form': form, } + extra_context = context.get_extra( + 'ASKBOT_EDIT_ANSWER_PAGE_EXTRA_CONTEXT', + request, + data + ) + data.update(extra_context) + return render(request, 'answer_edit.html', data) except exceptions.PermissionDenied, e: |