From 1e84f7289958c8381b7aab0f4e3a57f19bbe8f47 Mon Sep 17 00:00:00 2001 From: Denis Ledoux Date: Mon, 26 May 2014 11:49:26 +0200 Subject: [PATCH] [FIX] website_forum: do not check if the user has the group comment This access rights checks is meaningful for website_blog only --- addons/website_forum/controllers/main.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/addons/website_forum/controllers/main.py b/addons/website_forum/controllers/main.py index b94e818d0c5..b838795b076 100644 --- a/addons/website_forum/controllers/main.py +++ b/addons/website_forum/controllers/main.py @@ -329,13 +329,12 @@ class WebsiteForum(http.Controller): cr, uid, context = request.cr, request.uid, request.context if kwargs.get('comment') and post.forum_id.id == forum.id: # TDE FIXME: check that post_id is the question or one of its answers - if request.registry['res.users'].has_group(cr, uid, 'website_mail.group_comment'): - request.registry['forum.post'].message_post( - cr, uid, post.id, - body=kwargs.get('comment'), - type='comment', - subtype='mt_comment', - context=dict(context, mail_create_nosubcribe=True)) + request.registry['forum.post'].message_post( + cr, uid, post.id, + body=kwargs.get('comment'), + type='comment', + subtype='mt_comment', + context=dict(context, mail_create_nosubcribe=True)) return werkzeug.utils.redirect("/forum/%s/question/%s" % (slug(forum), slug(question))) @http.route('/forum//post//toggle_correct', type='json', auth="public", website=True)