summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2008-01-23 17:48:48 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2008-01-23 17:48:48 +0000
commitd54ba39e7aced22dd352273ec4af4b345a827363 (patch)
treea113ce49ecd5abe1369ec23e67b0846a9bfe9e39 /app
parent91dc13f4b22c45bee5cfd1d783d6544ae79afa04 (diff)
downloadredmine-d54ba39e7aced22dd352273ec4af4b345a827363.tar.gz
redmine-d54ba39e7aced22dd352273ec4af4b345a827363.zip
Fixed: can not lock a topic when creating it.
git-svn-id: http://redmine.rubyforge.org/svn/trunk@1095 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app')
-rw-r--r--app/models/message.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/message.rb b/app/models/message.rb
index 038665cce..12b1cd990 100644
--- a/app/models/message.rb
+++ b/app/models/message.rb
@@ -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