JustFly1984 / react-google-maps-api

React Google Maps API
MIT License
1.83k stars 445 forks source link

On closing/Unmounting the InfoWindow got error "Cannot read properties of undefined (reading 'matches')" #3215

Open deepak-as opened 1 year ago

deepak-as commented 1 year ago

On closing/unmount a info window got error this will trigger the React Error Boundary.

This error will also came on the Documentation page. Untitled_1

Console error log js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:184 Uncaught TypeError: Cannot read properties of undefined (reading 'matches') at .Qi (js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:184:200) at .Ui (js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:186:23) at .cj (js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:192:192) at infowindow.js:13:177 .Qi @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:184 .Ui @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:186 .cj @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:192 (anonymous) @ infowindow.js:13 setTimeout (async) .n.dispose @ infowindow.js:13 BI.close @ infowindow.js:17 d @ infowindow.js:17 .N @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:121 Rf @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:123 Rf @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:123 .O.set @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:291 .n.close @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:316 (anonymous) @ infowindow.js:10 _.N @ js?key=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&v=weekly&language=en&region=EN&libraries=drawing,places,visualization&callback=initMap:121 (anonymous) @ infowindow.js:4

kishore-as commented 1 year ago

I also face this same problem when unmounting infowindow