projects
/
zzz-floof.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added logout. Removed magical routing.
[zzz-floof.git]
/
floof
/
controllers
/
account.py
diff --git
a/floof/controllers/account.py
b/floof/controllers/account.py
index
0c53a6d
..
e4f39f3
100644
(file)
--- a/
floof/controllers/account.py
+++ b/
floof/controllers/account.py
@@
-72,6
+72,17
@@
class AccountController(BaseController):
# XXX send me where I came from
redirect_to('/')
# XXX send me where I came from
redirect_to('/')
+ def logout(self):
+ """Log user out."""
+
+ if 'user_id' in session:
+ del session['user_id']
+ session.save()
+
+ # XXX success message
+ # XXX send me where I came from
+ redirect_to('/')
+
def register(self):
"""Logging in with an unrecognized identity URL redirects here."""
def register(self):
"""Logging in with an unrecognized identity URL redirects here."""