Browse files

DRY up the layout method

  • Loading branch information...
1 parent ef01c37 commit 43bbbf451dc60cbd582a8ed20f027f39dea88bd8 @bry4n bry4n committed Jul 26, 2012
View
2 app/controllers/about_controller.rb
@@ -1,6 +1,6 @@
class AboutController < ApplicationController
- layout "layout"
def index
end
+
end
View
2 app/controllers/application_controller.rb
@@ -4,6 +4,8 @@ class ApplicationController < ActionController::Base
protect_from_forgery
before_filter :determine_os
+ layout 'layout'
+
rescue_from PageNotFound, :with => :page_not_found
# Mac, Windows, Linux are valid
View
2 app/controllers/books_controller.rb
@@ -1,7 +1,5 @@
class BooksController < ApplicationController
- layout 'layout'
-
before_filter :book_resource, :only => [:section, :chapter]
def show
View
2 app/controllers/community_controller.rb
@@ -1,6 +1,6 @@
class CommunityController < ApplicationController
- layout "layout"
def index
end
+
end
View
1 app/controllers/doc_controller.rb
@@ -1,5 +1,4 @@
class DocController < ApplicationController
- layout "layout"
before_filter :book_resource, :only => [:index]
View
1 app/controllers/downloads_controller.rb
@@ -1,5 +1,4 @@
class DownloadsController < ApplicationController
- layout "layout"
def index
end
View
1 app/controllers/site_controller.rb
@@ -1,5 +1,4 @@
class SiteController < ApplicationController
- layout "layout"
def index
end

0 comments on commit 43bbbf4

Please sign in to comment.