summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2009-05-10 08:49:45 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2009-05-10 08:49:45 +0000
commit7319e8e235ca2ad3d9b170072dcf286a1c79dcd7 (patch)
tree378b1c4f2fa978be8242dd2d376fa4d919bde41b /app
parent7e1ac0e602a8eb39b08543b8fb190d3456bb264c (diff)
downloadredmine-7319e8e235ca2ad3d9b170072dcf286a1c79dcd7.tar.gz
redmine-7319e8e235ca2ad3d9b170072dcf286a1c79dcd7.zip
Adds wiki comments length validation (#3308).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2720 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app')
-rw-r--r--app/models/wiki_content.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/app/models/wiki_content.rb b/app/models/wiki_content.rb
index e958e7b24..a72686b78 100644
--- a/app/models/wiki_content.rb
+++ b/app/models/wiki_content.rb
@@ -22,6 +22,7 @@ class WikiContent < ActiveRecord::Base
belongs_to :page, :class_name => 'WikiPage', :foreign_key => 'page_id'
belongs_to :author, :class_name => 'User', :foreign_key => 'author_id'
validates_presence_of :text
+ validates_length_of :comments, :maximum => 255
acts_as_versioned
class Version