Compare commits

...

3 Commits

Author SHA1 Message Date
Alexander Brown
177ad4da68 Merge branch 'main' into austin/undefined-widgets-fix 2026-01-13 15:29:06 -08:00
Austin Mroz
8d622e6519 Improve code quality 2025-11-12 18:57:31 -08:00
Austin Mroz
3021ea9afe Add safety check for undefined widgets 2025-11-12 18:57:31 -08:00

View File

@@ -4041,6 +4041,11 @@ export class LGraphNode
*/
#arrangeWidgets(widgetStartY: number): void {
if (!this.widgets || !this.widgets.length) return
const realWidgets = this.widgets.filter((w) => w)
if (realWidgets.length != this.widgets.length) {
console.error('Removing undefined widgets from', this)
this.widgets.splice(0, this.widgets.length, ...realWidgets)
}
const bodyHeight = this.bodyHeight
const startY =