diff --git a/x-pack/legacy/plugins/maps/public/connected_components/map/mb/tooltip_control/tooltip_control.js b/x-pack/legacy/plugins/maps/public/connected_components/map/mb/tooltip_control/tooltip_control.js
index b8f6710faa16b5..329d2b7fd2985a 100644
--- a/x-pack/legacy/plugins/maps/public/connected_components/map/mb/tooltip_control/tooltip_control.js
+++ b/x-pack/legacy/plugins/maps/public/connected_components/map/mb/tooltip_control/tooltip_control.js
@@ -174,43 +174,27 @@ export class TooltipControl extends React.Component {
return null;
}
- if (this.props.hasLockedTooltips) {
- return this.props.openTooltips.map(({ features, location, id }, index) => {
- const closeTooltip = () => {
- this.props.closeOnClickTooltip(id);
- };
- return (
-
- );
- });
- }
-
- return (
-
- );
+ return this.props.openTooltips.map(({ features, location, id, isLocked }, index) => {
+ const closeTooltip = isLocked
+ ? () => {
+ this.props.closeOnClickTooltip(id);
+ }
+ : this.props.closeOnHoverTooltip;
+ return (
+
+ );
+ });
}
}