onIdle should not be called without ref to actual map

This commit is contained in:
Vesa Luusua 2018-03-20 14:40:19 +02:00
parent fa78037482
commit f1362896c9

View file

@ -268,7 +268,9 @@ export class SearchMapComponent extends Component {
onListingClicked={this.onListingClicked}
onMapLoad={this.onMapLoadHandler}
onIdle={() => {
onIdle(this.googleMap);
if (this.googleMap) {
onIdle(this.googleMap);
}
}}
onCloseAsModal={() => {
if (onCloseAsModal) {