From 2fc80ef90a8265c03c23e6347735d0e3e1464165 Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Thu, 3 Sep 2015 13:18:58 -0500 Subject: [PATCH] Issue #688. Randos still at it, let's disable everywhere for a bit. --- webcompat/views.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/webcompat/views.py b/webcompat/views.py index aa0560892..82a417d8b 100644 --- a/webcompat/views.py +++ b/webcompat/views.py @@ -139,6 +139,13 @@ def index(): elif bug_form.validate_on_submit(): # copy the form so we can add the full UA string to it. form = request.form.copy() + # see https://github.com/webcompat/webcompat.com/issues/688 + if 'facebook' in form.get('url'): + msg = (u'Anonymous reporting for Facebook.com is temporarily ' + 'disabled. Please see https://github.com/webcompat/we' + 'bcompat.com/issues/688 for more details.') + flash(msg, 'notimeout') + return redirect(url_for('index')) form['ua_header'] = ua_header # Do we have an image ready to be uploaded? image = request.files['image'] @@ -153,13 +160,6 @@ def index(): session['form_data'] = form return redirect(url_for('login')) elif form.get('submit-type') == PROXY_REPORT: - # see https://github.com/webcompat/webcompat.com/issues/688 - if 'facebook' in form.get('url'): - msg = (u'Anonymous reporting for Facebook.com is temporarily ' - 'disabled. Please see https://github.com/webcompat/we' - 'bcompat.com/issues/688 for more details.') - flash(msg, 'notimeout') - return redirect(url_for('index')) response = report_issue(form, proxy=True).json() return redirect(url_for('thanks', number=response.get('number'))) else: