Skip to content

Commit dbb2cec

Browse files
committed
Remove unused geometryFunction if circle is being used
1 parent e79c252 commit dbb2cec

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/plugins/Gfi/src/store/actions/setupMultiSelection.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ export function setupMultiSelection({
5858
}
5959
if (multiSelect !== 'circle') {
6060
drawOptions.geometryFunction = createBox()
61+
} else {
62+
delete drawOptions.geometryFunction
6163
}
6264
const draw = new Draw(drawOptions)
6365
draw.on('drawstart', () => {
@@ -77,7 +79,6 @@ export function setupMultiSelection({
7779
)
7880
map.addInteraction(draw)
7981
}
80-
8182
if (directSelect) {
8283
map.on('click', ({ coordinate, originalEvent }) => {
8384
if (!isDrawing(map)) {

0 commit comments

Comments
 (0)