From a9c35b3ca8492b38a7876eaee033398d35d9dabf Mon Sep 17 00:00:00 2001 From: Johann-S Date: Wed, 14 Aug 2019 18:02:41 +0200 Subject: Remove useless check for null object with spread operator --- js/src/tooltip/tooltip.js | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'js/src/tooltip') diff --git a/js/src/tooltip/tooltip.js b/js/src/tooltip/tooltip.js index 8bf998468..99ac29af6 100644 --- a/js/src/tooltip/tooltip.js +++ b/js/src/tooltip/tooltip.js @@ -483,15 +483,10 @@ class Tooltip { onUpdate: data => this._handlePopperPlacementChange(data) } - let resultConfig = defaultBsConfig - if (this.config.popperConfig) { - resultConfig = { - ...defaultBsConfig, - ...this.config.popperConfig - } + return { + ...defaultBsConfig, + ...this.config.popperConfig } - - return resultConfig } _addAttachmentClass(attachment) { -- cgit v1.2.3