diff options
Diffstat (limited to 'app/models/node.rb')
| -rw-r--r-- | app/models/node.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/models/node.rb b/app/models/node.rb index 170ca1c..a6e3867 100644 --- a/app/models/node.rb +++ b/app/models/node.rb | |||
| @@ -10,6 +10,9 @@ class Node < ActiveRecord::Base | |||
| 10 | # Callbacks | 10 | # Callbacks |
| 11 | after_create :initialize_empty_page | 11 | after_create :initialize_empty_page |
| 12 | 12 | ||
| 13 | # Validations | ||
| 14 | validates_length_of :slug, :within => 3..40 | ||
| 15 | |||
| 13 | # Class methods | 16 | # Class methods |
| 14 | 17 | ||
| 15 | # Returns a page for a given node. If no revision is supplied, it returns | 18 | # Returns a page for a given node. If no revision is supplied, it returns |
