From 94adf6256647548030f968fcbb2b29a7f20e2a9b Mon Sep 17 00:00:00 2001 From: Timo Stollenwerk Date: Sat, 31 Oct 2009 16:42:04 +0000 Subject: [PATCH] do not show moderation message when user has manage rights. svn path=/plone.app.discussion/trunk/; revision=30997 --- plone/app/discussion/browser/comments.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plone/app/discussion/browser/comments.py b/plone/app/discussion/browser/comments.py index 66b07b9..fdb4c74 100644 --- a/plone/app/discussion/browser/comments.py +++ b/plone/app/discussion/browser/comments.py @@ -200,9 +200,11 @@ class CommentForm(extensible.ExtensibleForm, form.Form): # Add comment to the conversation comment_id = conversation.addComment(comment) + can_manage = getSecurityManager().checkPermission('Manage portal', aq_inner(self.context)) + # Show info message when comment moderation is enabled if wf.getChainForPortalType('Discussion Item') == \ - ('comment_review_workflow',): + ('comment_review_workflow',) and not can_manage: IStatusMessage(self.context.REQUEST).addStatusMessage( _("Your comment awaits moderator approval."),