Compare commits
No commits in common. "a6b2f03d78b3bab271d4b11753e5ba8eab3bc627" and "75e2ddf51f65d0b35db50229f5735b57024e9343" have entirely different histories.
a6b2f03d78
...
75e2ddf51f
9
app.py
9
app.py
@ -31,10 +31,11 @@ def inject_user():
|
||||
# Create a new route
|
||||
@app.route('/')
|
||||
def index():
|
||||
# return 'Hello World'
|
||||
|
||||
if current_user.is_authenticated:
|
||||
habits = current_user.get_habits()
|
||||
name = "Hallo " + current_user.name + "du hurensohn"
|
||||
name = "Hallo " + current_user.name
|
||||
else:
|
||||
habits = []
|
||||
name = "Bitte melde dich an."
|
||||
@ -49,6 +50,12 @@ def index():
|
||||
)
|
||||
|
||||
|
||||
@app.route('/test')
|
||||
@login_required
|
||||
def secret():
|
||||
return 'Pssst!'
|
||||
|
||||
|
||||
@app.route('/login')
|
||||
@anonymous_required
|
||||
def login():
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user