fix $limit should be $options['limit']
This commit is contained in:
parent
328b804465
commit
2b66b28689
|
@ -194,12 +194,12 @@ private $defaults = array(
|
||||||
}
|
}
|
||||||
if ( isset($options['limit']) ) {
|
if ( isset($options['limit']) ) {
|
||||||
if ( is_integer($options['limit']) or ctype_digit($options['limit']) ) {
|
if ( is_integer($options['limit']) or ctype_digit($options['limit']) ) {
|
||||||
$sql .= ' LIMIT ' . $limit;
|
$sql .= ' LIMIT ' . $options['limit'];
|
||||||
} else {
|
} else {
|
||||||
$backTrace = debug_backtrace();
|
$backTrace = debug_backtrace();
|
||||||
$file = $backTrace[1]['file'];
|
$file = $backTrace[1]['file'];
|
||||||
$line = $backTrace[1]['line'];
|
$line = $backTrace[1]['line'];
|
||||||
Error("Invalid value for limit($limit) passed to Control::find from $file:$line");
|
Error("Invalid value for limit(".$options['limit'].") passed to Control::find from $file:$line");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue