mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-12 20:13:59 +02:00
@@ -264,10 +264,14 @@ func Seq(args ...interface{}) ([]int, error) {
|
||||
}
|
||||
}
|
||||
|
||||
// sanity check
|
||||
if last < -100000 {
|
||||
return nil, errors.New("size of result exeeds limit")
|
||||
}
|
||||
size := int(((last - first) / inc) + 1)
|
||||
|
||||
// sanity check
|
||||
if size > 2000 {
|
||||
if size <= 0 || size > 2000 {
|
||||
return nil, errors.New("size of result exeeds limit")
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user