Skip to content

Instantly share code, notes, and snippets.

@Jarred-Sumner
Created September 5, 2012 07:33
Show Gist options
  • Save Jarred-Sumner/3632669 to your computer and use it in GitHub Desktop.
Save Jarred-Sumner/3632669 to your computer and use it in GitHub Desktop.
class FeedController < ApplicationController
def index
@feeds = Feed.last_day
if @feeds.blank?
@feeds = Feed.last_week
end
end
def show
@feed = Feed.find(params[:id])
@status = @feed.statuses.first
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment