lib/vidibus/user/extensions.rb in vidibus-user-0.0.10 vs lib/vidibus/user/extensions.rb in vidibus-user-1.0.0
- old
+ new
@@ -1,5 +1,16 @@
-require "user/extensions/controller"
+require 'vidibus/user/extensions/controller'
+require 'vidibus/user/extensions/helper'
-ActiveSupport.on_load(:action_controller) do
- include Vidibus::User::Extensions::Controller
+if defined?(ActiveSupport)
+ ActiveSupport.on_load(:action_controller) do
+ include Vidibus::User::Extensions::Controller
+ end
+
+ ActiveSupport.on_load(:application_helper) do
+ include Vidibus::User::Extensions::Helper
+ end
+
+ ActiveSupport.on_load(:action_view) do
+ include Vidibus::User::Extensions::Helper
+ end
end