Cannot use acts_as_ferret on legacy tables or tables with a

when i used “find_by_contents” on a legacy table with a different
primary_key than “id” i always got results=nil even when total_hits was

0

as a quick fix i changed line 261 in “class_methods.rb”
from:
conditions = [ “#{self.table_name}.id in (?)”, id_array ]

to:
conditions = [ “#{self.table_name}.#{self.primary_key} in (?)”,
id_array ]

i tried to report that as a ticket on
projects.jkraemer.net/acts_as_ferret/ but something is broken there :frowning:
→ internal error “Akismet rejected spam”

On Fri, Dec 01, 2006 at 11:42:15AM +0100, Ralf V. wrote:

id_array ]
this is already fixed in svn trunk.

i tried to report that as a ticket on
projects.jkraemer.net/acts_as_ferret/ but something is broken there :frowning:
→ internal error “Akismet rejected spam”

I know, something is broken with the akismet plugin. But without it,
spam is even worse. still looking for a spam-proof wiki+issue-tracking
solution…

Jens


webit! Gesellschaft für neue Medien mbH www.webit.de
Dipl.-Wirtschaftsingenieur Jens Krämer [email protected]
Schnorrstraße 76 Tel +49 351 46766 0
D-01069 Dresden Fax +49 351 46766 66