# File lib/abingo_sugar.rb, line 31 def abingo_mark_human(abingo) textual_result = "1" begin a = params[:a].to_i b = params[:b].to_i c = params[:c].to_i if (request.method == :post && (a + b == c)) abingo.human! else textual_result = "0" end rescue #If a bot doesn't pass a, b, or c, to_i will fail. This scarfs up the exception, to save it from polluting our logs. textual_result = "0" end render :text => textual_result, :layout => false #Not actually used by browser end