1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Update documentation for observers to reflect new configuration system.

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2766 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
Marcel Molina 2005-10-27 16:06:04 +00:00
parent beff664f2a
commit 0ba5bd583b

View file

@ -74,9 +74,10 @@ module ActiveRecord
#
# == Triggering Observers
#
# In order to activate an observer, you need to call Observer.instance. In Rails, this can be done in controllers
# using the short-hand of for example observer :comment_observer. Or directly from Active Record, with
# ActiveRecord::Base.observer(:comment_observer).
# In order to activate an observer, list it in the <tt>config.active_record.observers</tt> configuration setting in your
# <tt>config/environment.rb</tt> file.
#
# config.active_record.observers = :comment_observer, :signup_observer
class Observer
include Singleton