Skip to content

Commit

Permalink
Merge pull request FOSDEM#70 from FOSDEM/fix_massmail
Browse files Browse the repository at this point in the history
Fix django deprecation error
  • Loading branch information
johanvdw committed Jan 31, 2024
2 parents ce30de5 + 2097415 commit b41d9f2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions volunteers/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ def mass_mail_volunteer(self, request, queryset):
'Mail with subject "{}" sent to {} volunteer{}.'.format(subject, count, plural))
return HttpResponseRedirect(request.get_full_path())
if not form:
form = self.MassMailForm(initial={'_selected_action': request.POST.getlist(admin.ACTION_CHECKBOX_NAME)})
form = self.MassMailForm(initial={'_selected_action': request.POST.getlist("_selected_action")})
return render(request, 'admin/massmail.html', {'volunteers': volunteers,
'massmail_form': form,
})
Expand Down Expand Up @@ -415,7 +415,7 @@ def mass_mail_volunteer(self, request, queryset):
'Mail with subject "{}" sent to {} volunteer{}.'.format(subject, count, plural))
return HttpResponseRedirect(request.get_full_path())
if not form:
form = self.MassMailForm(initial={'_selected_action': request.POST.getlist(admin.ACTION_CHECKBOX_NAME)})
form = self.MassMailForm(initial={'_selected_action': request.POST.getlist("_selected_action")})
return render(request, 'admin/massmail.html', {'volunteers': queryset,
'massmail_form': form,
})
Expand Down

0 comments on commit b41d9f2

Please sign in to comment.