summaryrefslogtreecommitdiff
path: root/app/controllers
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/application_controller.rb12
-rw-r--r--app/controllers/home_controller.rb3
2 files changed, 15 insertions, 0 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb
index 06b245a..62d9df2 100644
--- a/app/controllers/application_controller.rb
+++ b/app/controllers/application_controller.rb
@@ -3,4 +3,16 @@ class ApplicationController < ActionController::Base
ActiveSupport.run_load_hooks(:application_controller, self)
+ protected
+
+ #
+ # Allows us to pass through bold text to flash messages. See format_flash() for where this is reversed.
+ #
+ # TODO: move to core
+ #
+ def bold(str)
+ "[b]#{str}[/b]"
+ end
+ helper_method :bold
+
end
diff --git a/app/controllers/home_controller.rb b/app/controllers/home_controller.rb
index 4e1983a..120541e 100644
--- a/app/controllers/home_controller.rb
+++ b/app/controllers/home_controller.rb
@@ -1,6 +1,9 @@
class HomeController < ApplicationController
def index
+ if logged_in?
+ redirect_to user_overview_url(current_user)
+ end
debugger if params[:debug]
end
end