Added some authentication methods.
This commit is contained in:
parent
b56cd48dec
commit
e61fee8258
@ -71,6 +71,7 @@ class BlogController(BaseController):
|
||||
c.page_title = c.post.title
|
||||
return render(u'/blog/view.mako')
|
||||
|
||||
@authenticate()
|
||||
def comment_POST(self, id):
|
||||
if not id:
|
||||
h.flash.set_message(u'There was a problem submitting your comment.', u'error')
|
||||
|
@ -48,6 +48,7 @@ class PostController(BaseController):
|
||||
c.page_title = 'Edit Post: %s' % c.post.title
|
||||
return render(u'/post/edit.mako')
|
||||
|
||||
@authenticate()
|
||||
def edit_POST(self, id=None):
|
||||
url = utils.generate_url(c.form_values[u'title'])
|
||||
if id is None:
|
||||
|
Reference in New Issue
Block a user