Skip to content
Snippets Groups Projects
Commit ac49e352 authored by Todd Dembrey's avatar Todd Dembrey
Browse files

remove the superfluous kwarg (new is submission)

parent 249a0847
No related branches found
No related tags found
No related merge requests found
......@@ -21,7 +21,7 @@ class MessageAdapter:
class ActivityAdapter:
messages = {
MESSAGES.NEW_SUBMISSION: 'Submitted {submission.title} for {submission.page.title}',
MESSAGES.UPDATE_LEAD: 'Lead changed from {old.lead} to {new.lead}',
MESSAGES.UPDATE_LEAD: 'Lead changed from {old.lead} to {submission.lead}',
MESSAGES.NEW_DETERMINATION: 'Created a determination for {submission.title}',
MESSAGES.DETERMINATION_OUTCOME: 'Sent a {submission.determination.get_outcome_display} determination for {submission.title}:\r\n{determination.clean_message}',
MESSAGES.INVITED_TO_PROPOSAL: '{submission.title} has been invited to submit a proposal.',
......
......@@ -98,13 +98,11 @@ class UpdateLeadView(DelegatedViewMixin, UpdateView):
# Fetch the old lead from the database
old = copy(self.get_object())
response = super().form_valid(form)
new = form.instance
messenger(
MESSAGES.UPDATE_LEAD,
user=self.request.user,
submission=self.kwargs['submission'],
submission=form.instance,
old=old,
new=new,
)
return response
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment