When there are nested options, the option on the third layer cannot be selected properly

The data structure can display nested options normally by providing nested children.
The select function works properly when there are only two levels of options.

But when there is a third level option, it doesn’t work properly when selected.

For example: https://codepen.io/Xiuer0x0/pen/RwdKEVB

  • Browser: Chrome version 120.0.6099.110 (64 bit)
  • Select2 verstion: 4.0.13