undefined method `find_all'

i have modified my code as follows:

<%= collection_select(:category, :id, @categories, :id, :category_type,
options ={:prompt => "-Select a Category"}, :class =>"category") %>

i Hav also modified the definition in my controllers as follows:

@categories = category.find(:all)

but it still gives me the following error

You have a nil object when you didn't expect it!

You might have expected an instance of Array.
The error occurred while evaluating nil.map

seems there something i dont get

i have modified my code as follows:

<%= collection_select(:category, :id, @categories, :id, :category_type,
options ={:prompt => "-Select a Category"}, :class =>"category") %>

i Hav also modified the definition in my controllers as follows:

@categories = category.find(:all)

but it still gives me the following error

You have not said, but I presume that you mean that it still gives you
the error with Category.find. How did you get on with ruby-debug?

Colin