Skip to content

Commit

Permalink
Add nullcheck to snap-to-grid setting
Browse files Browse the repository at this point in the history
  • Loading branch information
christian-byrne committed Sep 17, 2024
1 parent 3fe4b4b commit 1dcc39e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/extensions/core/snapToGrid.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ app.registerExtension({
'When dragging and resizing nodes while holding shift they will be aligned to the grid, this controls the size of that grid.',
defaultValue: LiteGraph.CANVAS_GRID_SIZE,
onChange(value) {
LiteGraph.CANVAS_GRID_SIZE = +value
LiteGraph.CANVAS_GRID_SIZE = +value || 10
}
})

Expand Down

0 comments on commit 1dcc39e

Please sign in to comment.