feat: PEP 8 formatting
This commit is contained in:
parent
0dbdc5189d
commit
078968ddc4
@ -21,7 +21,6 @@ Hangouts Chat bot that responds to events and messages from a room asynchronousl
|
|||||||
|
|
||||||
|
|
||||||
import logging
|
import logging
|
||||||
from os import environ
|
|
||||||
|
|
||||||
from flask import Blueprint, render_template, request, json
|
from flask import Blueprint, render_template, request, json
|
||||||
from google.oauth2 import service_account
|
from google.oauth2 import service_account
|
||||||
@ -31,7 +30,6 @@ logging.basicConfig(filename='example.log', level=logging.DEBUG)
|
|||||||
|
|
||||||
chatbot = Blueprint('chatbot', __name__)
|
chatbot = Blueprint('chatbot', __name__)
|
||||||
|
|
||||||
|
|
||||||
scopes = ['https://www.googleapis.com/auth/chat.bot']
|
scopes = ['https://www.googleapis.com/auth/chat.bot']
|
||||||
credentials = service_account.Credentials.from_service_account_file('./priceybot2/config/service-acct.json')
|
credentials = service_account.Credentials.from_service_account_file('./priceybot2/config/service-acct.json')
|
||||||
# credentials, project_id = google.auth.default()
|
# credentials, project_id = google.auth.default()
|
||||||
@ -132,5 +130,3 @@ def home_get():
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
return render_template('home.html')
|
return render_template('home.html')
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
from flask import Blueprint, render_template
|
from flask import Blueprint, render_template
|
||||||
from flask_login import login_required, current_user
|
from flask_login import login_required, current_user
|
||||||
from . import db
|
|
||||||
|
|
||||||
main = Blueprint('main', __name__)
|
main = Blueprint('main', __name__)
|
||||||
|
|
||||||
|
|
||||||
@main.route('/')
|
@main.route('/')
|
||||||
def index():
|
def index():
|
||||||
return render_template('index.html')
|
return render_template('index.html')
|
||||||
@ -12,4 +12,9 @@ def index():
|
|||||||
@main.route('/profile')
|
@main.route('/profile')
|
||||||
@login_required
|
@login_required
|
||||||
def profile():
|
def profile():
|
||||||
return render_template('profile.html', name=current_user.name, google_id=current_user.google_id, is_admin=current_user.administrator)
|
return render_template(
|
||||||
|
'profile.html',
|
||||||
|
name=current_user.name,
|
||||||
|
google_id=current_user.google_id,
|
||||||
|
is_admin=current_user.administrator
|
||||||
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user