search for: subscribed_by

Displaying 1 result from an estimated 1 matches for "subscribed_by".

2010 Jul 13
1
NoMethodError in UsersController#show
...ollers and models: Users_Controller: def show #@user = User.find(params[:id]) @user = User.find_by_login(params[:login]) #@feed_items = @user.feed @feed_items = @user.feed end Users Model: def feed #Post.all(:conditions => ["user_id = ?", id]) Post.from_users_subscribed_by(self) end Post Model (using SQLite3) : named_scope :from_users_subscribed_by, lambda { |user| subscribed_by(user) } private # Return an SQL condition for users followed by the given user. # We include the user''s own id as well. def self.subscribed_by(user) subscribed...