aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--servo/views/admin.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/servo/views/admin.py b/servo/views/admin.py
index 9924f2b..5d1da4a 100644
--- a/servo/views/admin.py
+++ b/servo/views/admin.py
@@ -613,10 +613,9 @@ def edit_queue(request, pk=None):
if form.is_valid():
try:
queue = form.save()
- queue.user_set = form.cleaned_data['users']
- queue.save()
+ queue.user_set.set(form.cleaned_data['users'])
except Exception as e:
- messages.error(request, _('Failed to save queue'))
+ messages.error(request, _('Failed to save queue (%s)' % e))
return render(request, 'admin/queues/form.html', locals())
formset = StatusFormSet(request.POST, instance=queue)