Class: Writefully::PostsController

Inherits:
ApplicationController show all
Defined in:
app/controllers/writefully/posts_controller.rb

Instance Method Summary collapse

Methods inherited from ApplicationController

#authenticate_wf_authorship!, #set_flash, #wf_authorship_signed_in?

Instance Method Details

#indexObject



5
6
7
8
# File 'app/controllers/writefully/posts_controller.rb', line 5

def index
  @site = get_site
  @posts = @site.posts
end

#showObject



10
11
12
13
# File 'app/controllers/writefully/posts_controller.rb', line 10

def show
  @site = get_site
  @post = @site.posts.friendly.find(params[:id])
end