title: rails3 before_filter cause Filter chain halted as :authenticate rendered or redirected error
body: <p>In my index.html, i use &lt;%= render 'rates/rate_form'%>
  to render the rate form, and the form is ajax.The content of _rate_form is:</p>
  
  <pre><code>   `&lt;%= form_for [@image, Rate.new], :remote=&gt;true do |f| %&gt;  
  &lt;input type="hidden" name="image_id" value="&lt;%= @image.id%&gt;"/&gt;
  &lt;button type="submit"&gt; Rate&lt;/button&gt;
  &lt;% end %&gt;`
  </code></pre>
  
  <p>In my Rates controller, i defined one before_filter, only signed in use can create rate.
      class RatesController &lt; ApplicationController
       before_filter :authenticate, :only=> :create</p>
  
  <pre><code>def create
  @rate=Rate.new(:rate=&gt;1)
  
  respond_to do |format|
    if @rate.save
      format.html { redirect_to(@rate) }
      format.js 
    end
  end
  end
  </code></pre>
  
  <p>in my sesson_helper file:</p>
  
  <pre><code> def authenticate
     redirect_to signin_url unless signed_in? 
   end
  </code></pre>
  
  <p>The log is:</p>
  
  <pre><code>Redirected to http://localhost:3000/signin
  Filter chain halted as :authenticate rendered or redirected
  Completed 302 Found in 3ms (ActiveRecord: 0.7ms)
  
  
  Started GET "/signin" for 127.0.0.1 at 2013-04-28 12:36:56 +0300
  Processing by SessionsController#new as JS
  Rendered sessions/new.html.erb within layouts/application (1.3ms)
  User Load (0.9ms)  SELECT "users".* FROM "users" WHERE "users"."id" IS NULL LIMIT 1
  Rendered sessions/new.html.erb (1.2ms)
  Rendered layouts/_nav.html.erb (4.8ms)
  Rendered layouts/_search.html.erb (0.6ms)
  Rendered layouts/_notice_div.html.erb (0.1ms)
  Completed 200 OK in 26ms (Views: 24.3ms | ActiveRecord: 0.9ms)
  </code></pre>
  
  <p>When i click the Rate button, there is error in console: Filter chain halted as :deny_access rendered or redirected
  Do you have any idea how to solve it? Thanks a lot!</p>