diff --git a/pfwb_archives_proxy/settings.py b/pfwb_archives_proxy/settings.py index f6a39b5..5958b1c 100644 --- a/pfwb_archives_proxy/settings.py +++ b/pfwb_archives_proxy/settings.py @@ -72,8 +72,7 @@ WSGI_APPLICATION = 'pfwb_archives_proxy.wsgi.application' # Database # https://docs.djangoproject.com/en/2.2/ref/settings/#databases -DATABASES = { -} +DATABASES = {} # Password validation diff --git a/pfwb_archives_proxy/views.py b/pfwb_archives_proxy/views.py index 253b3c9..b6582a8 100644 --- a/pfwb_archives_proxy/views.py +++ b/pfwb_archives_proxy/views.py @@ -30,7 +30,17 @@ def redirect(request, sess, no, nodoc=None, anx=None): else: query += ' AND type NOT IN %(distinct_types)s' - cur.execute(query, {'sess': sess, 'no': no, 'nodoc': nodoc, 'anx': anx, 'type': type_, 'distinct_types': distinct_types}) + cur.execute( + query, + { + 'sess': sess, + 'no': no, + 'nodoc': nodoc, + 'anx': anx, + 'type': type_, + 'distinct_types': distinct_types, + }, + ) rows = cur.fetchall() if rows: url = 'https://archives.pfwb.be/%s' % rows[0][0]