need help with acts_as_ferret and will_paginate to play nice together
Posted
by ironmantis7x
on Stack Overflow
See other posts from Stack Overflow
or by ironmantis7x
Published on 2010-04-29T14:09:55Z
Indexed on
2010/04/29
14:27 UTC
Read the original article
Hit count: 287
I have installed will_paginate and acts_as_ferret on my system for ruby rails.
My paginate seems to work fine before installing acts_as_ferret. When I put in the code to do searching I get the following error:
NoMethodError in Community#search
Showing app/views/community/_result_summary.rhtml where line #3 raised:
undefined method `total_entries' for []:Array
Extracted source (around line #3):
1: <% if @users %>
2: <p>
3: Found <%= pluralize(@users.total_entries, "match") %>.
4: </p>
5: <% end %>
If I take out the search function, paginate works but it's pointless because I can't do searches. Can any one help me out on this one??
Thanks!!
Stephen
© Stack Overflow or respective owner