Skip to content

Commit 01916e6

Browse files
committed
Unset tomSelect after destroying the instance
fix #407
1 parent 8e84d49 commit 01916e6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/Autocomplete/assets/src/controller.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ export default class extends Controller {
4141

4242
disconnect() {
4343
this.tomSelect.destroy();
44+
// Fixes https://github.com/symfony/ux/issues/407
45+
this.tomSelect = undefined;
4446
}
4547

4648
#getCommonConfig(): Partial<TomSettings> {

0 commit comments

Comments
 (0)