Skip to content

Commit

Permalink
Merge pull request comfy#216 from RobWu/site_index
Browse files Browse the repository at this point in the history
Set sites only if not already defined.
  • Loading branch information
GBH committed Sep 24, 2012
2 parents 236ac1c + bdc3884 commit 6bb4198
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/controllers/cms_admin/sites_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class CmsAdmin::SitesController < CmsAdmin::BaseController
def index
return redirect_to :action => :new if Cms::Site.count == 0
@site = Cms::Site.find_by_id(session[:site_id])
@sites = Cms::Site.all
@sites ||= Cms::Site.all
end

def new
Expand Down

0 comments on commit 6bb4198

Please sign in to comment.