I'll put this back. This works and uses single transaction, clear()/add() uses 2 transactions.

This commit is contained in:
Pēteris Caune 2015-12-07 21:09:54 +02:00
parent ded7038145
commit 53edb555dc

View File

@ -215,8 +215,7 @@ def channels(request):
return HttpResponseForbidden()
new_checks.append(check)
channel.checks.clear()
channel.checks.add(*new_checks)
channel.checks = new_checks
return redirect("hc-channels")
channels = Channel.objects.filter(user=request.user).order_by("created")