Am I Putting my Helper in the Wrong Place?

Hi,

This will probably be an easy one as I must be overlooking something obvious. I'm trying to set up a helper method that file find the first photo belonging to a product ( photo.sort should == 1).

def product_list_photo(id)    Photo.find(:first, :conditions => ["photo_id = ?", id], :sort => "sort ASC") end

This helper is in products_helper.rb. It needs to be used in filecolumn to pull up the appropriate image

  <%= image_tag url_for_file_column(product_list_photo(product.id), "title_photo") %>

For whatever reason I keep getting an undefined variable or method error. Am I doing something really obvious wrong?

Thanks!

1) :sort is not an option user :order. 2) Models should be accessed from the controller only 3) Post the error message