From 71ed95d2421330489574bbebc92cd7488edf216a Mon Sep 17 00:00:00 2001 From: Joenio Costa Date: Tue, 11 Oct 2011 06:51:25 -0300 Subject: [PATCH] Do not check captcha answer for comments of logged users --- app/controllers/public/content_viewer_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/public/content_viewer_controller.rb b/app/controllers/public/content_viewer_controller.rb index 4c9f208..6494c30 100644 --- a/app/controllers/public/content_viewer_controller.rb +++ b/app/controllers/public/content_viewer_controller.rb @@ -119,7 +119,7 @@ class ContentViewerController < ApplicationController def add_comment @comment.author = user if logged_in? @comment.article = @page - if (@comment.reply_of_id || verify_recaptcha(:model => @comment, :message => _('Please type the words correctly'))) && @comment.save + if (logged_in? || @comment.reply_of_id || verify_recaptcha(:model => @comment, :message => _('Please type the words correctly'))) && @comment.save @page.touch @comment = nil # clear the comment form redirect_to :action => 'view_page', :profile => params[:profile], :page => @page.explode_path, :view => params[:view] -- libgit2 0.21.2