From 3467f5da31ee2ca9e5af7861b43eade2c19a0868 Mon Sep 17 00:00:00 2001 From: Alexandr Date: Tue, 15 Aug 2023 05:11:07 +0300 Subject: [PATCH] Refactor: Top langs card: Use default value instead if statement --- src/cards/top-languages-card.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/cards/top-languages-card.js b/src/cards/top-languages-card.js index b9fc655d3d25f..f2fda70ece155 100644 --- a/src/cards/top-languages-card.js +++ b/src/cards/top-languages-card.js @@ -719,7 +719,7 @@ const getDefaultLanguagesCountByLayout = ({ layout, hide_progress }) => { const renderTopLanguages = (topLangs, options = {}) => { const { hide_title = false, - hide_border, + hide_border = false, card_width, title_color, text_color, @@ -808,9 +808,7 @@ const renderTopLanguages = (topLangs, options = {}) => { if (disable_animations) card.disableAnimations(); - if (hide_border) { - card.setHideBorder(hide_border); - } + card.setHideBorder(hide_border); card.setHideTitle(hide_title); card.setCSS( `