Fix the new superuser_required decorator when not logged in.
Review Request #8379 — Created Sept. 3, 2016 and submitted
The
@superuser_required
decorator was passing a dictionary of keyword
arguments, instead of the keyword arguments themselves, to thelogin()
method. This brokelogin()
, which saw that dictionary as the
template_name
argument.This fixes the code to pass those in as keyword arguments, and fixes the
name of one of the arguments, allowing the view to show a login page
instead of a 500.
Tested visiting as a logged-out user. Saw a login form. Logged in using
it and was taken to the settings page.