Browse Source

allow larger slugs if necessary

euromark 11 years ago
parent
commit
b346aa64ca
1 changed files with 4 additions and 1 deletions
  1. 4 1
      Model/Behavior/SluggedBehavior.php

+ 4 - 1
Model/Behavior/SluggedBehavior.php

@@ -94,7 +94,10 @@ class SluggedBehavior extends Behavior {
 
 		if (!$this->_config['length']) {
 			$length = $table->schema()->column($this->_config['field'])['length'];
-			$this->_config['length'] = min((int)$length, 255);
+			if (!$length) {
+				$length = 255;
+			}
+			$this->_config['length'] = $length;
 		}
 
 		$this->_table = $table;