File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed
Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -74,7 +74,9 @@ class Circle extends Component {
7474 }
7575
7676 onCircleCallback ( callback , event ) {
77- this . props [ callback ] ( this . circle , event ) ;
77+ if ( this . props [ callback ] ) {
78+ this . props [ callback ] ( this . circle , event ) ;
79+ }
7880 }
7981
8082 renderCircle ( props ) {
@@ -158,8 +160,8 @@ Circle.defaultProps = {
158160 onMouseUp : ( circle ) => { } ,
159161 onRadiusChanged : ( circle ) => { } ,
160162 onRightClick : ( circle ) => { } ,
161- onVisibleChange : ( circle ) => { } ,
162- onZIndexChange : ( circle ) => { } ,
163+ onVisibleChanged : ( circle ) => { } ,
164+ onZIndexChanged : ( circle ) => { } ,
163165} ;
164166
165167export default Circle ;
Original file line number Diff line number Diff line change @@ -68,7 +68,9 @@ class Marker extends Component {
6868 }
6969
7070 onMarkerCallback ( callback , event ) {
71- this . props [ callback ] ( this . marker , event ) ;
71+ if ( this . props [ callback ] ) {
72+ this . props [ callback ] ( this . marker , event ) ;
73+ }
7274 }
7375
7476 renderMarker ( props ) {
You can’t perform that action at this time.
0 commit comments