Fixed: can not lock a topic when creating it.
git-svn-id: http://redmine.rubyforge.org/svn/trunk@1095 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
91dc13f4b2
commit
d54ba39e7a
|
@ -36,7 +36,7 @@ class Message < ActiveRecord::Base
|
|||
|
||||
def validate_on_create
|
||||
# Can not reply to a locked topic
|
||||
errors.add_to_base 'Topic is locked' if root.locked?
|
||||
errors.add_to_base 'Topic is locked' if root.locked? && self != root
|
||||
end
|
||||
|
||||
def after_create
|
||||
|
|
Loading…
Reference in New Issue