diff --git a/app/controllers/application.rb b/app/controllers/application.rb index eb7f9ab..aed72d0 100644 --- a/app/controllers/application.rb +++ b/app/controllers/application.rb @@ -38,7 +38,8 @@ class ApplicationController < ActionController::Base end def load_profile - @profile = Profile.find_by_identifier(params[:profile]) + @profile = Profile.find_by_identifier(params[:profile]) + @profile ||= Profile.find(:first) #This is not correct it was made to the system don't crash raise "The profile must be loaded %s" % params[:profile].to_s if @profile.nil? end -- libgit2 0.21.2