Problem accessing item using has many through

In the controller the first two statement work ok but the third @ingredients=Recipe.ingredients generates an error

"undefined method `ingredients' for Recipe:Class"

It should be @recipe.ingredients


just spotted the other problem: @recipe isn't a single @recipe as I expected, but an array of recipes.


@bakery_output = BakeryOutput.find(params[:id], :include => [:recipe, :customer])      @recipe = Recipe.find(:all, :conditions => ["id = ?", @bakery_output.recipe_id])

should be @recipe = @bakery_output.recipe.