force message to update its watchers and watcher_users when creating a new watcher in its after_create hook

pull/1186/head
Philipp Tessenow 12 years ago
parent 8ec06df04c
commit ddc6cdec54
  1. 3
      app/models/message.rb

@ -113,5 +113,8 @@ class Message < ActiveRecord::Base
def add_author_as_watcher
Watcher.create(:watchable => self.root, :user => author)
# update watchers and watcher_users
watchers(true)
watcher_users(true)
end
end

Loading…
Cancel
Save