class AdminNotifier < ActionMailer::Base
+ include AbstractController::Callbacks
+
default from: Rails.configuration.admin_notifier_email_from
+ before_filter :load_variables
def new_user(user)
@user = user
end
end
+private
+ def load_variables
+ if Rails.configuration.respond_to?('workbench_address') and
+ not Rails.configuration.workbench_address.nil? and
+ not Rails.configuration.workbench_address.empty? then
+ @wb_address = Rails.configuration.workbench_address.sub(/\/$/,'') + '/users'
+ else
+ @wb_address = ''
+ end
+ end
+
end