Fixed enumerable for ActiveRecord 3.1