diff options
-rw-r--r-- | ui/form/ListScrollForm.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ui/form/ListScrollForm.js b/ui/form/ListScrollForm.js index 38fd2a2..78c376f 100644 --- a/ui/form/ListScrollForm.js +++ b/ui/form/ListScrollForm.js @@ -271,7 +271,7 @@ module.exports = class ListScrollForm extends Form { // past. let size = 0 - for (let i = 0; i < this.scrollItems; i++) { + for (let i = 0; i < Math.min(this.scrollItems, this.inputs.length); i++) { if (this.layoutType === 'horizontal') { size += this.inputs[i].w } else { |