diff --git a/src/components/Roof2.jsx b/src/components/Roof2.jsx index 70deec93..f77f68c0 100644 --- a/src/components/Roof2.jsx +++ b/src/components/Roof2.jsx @@ -594,13 +594,12 @@ export default function Roof2(props) { } const changeLength = (e) => { - setScale(e) const polygon = canvas?.getActiveObject() - if (polygon.type !== 'QPolygon') { + if (polygon?.type !== 'QPolygon') { return } - + setScale(e) polygon.setScaleX(e) canvas?.renderAll()