Skip to content

Commit

Permalink
EPMRPP-76492 || code review fixes - 1
Browse files Browse the repository at this point in the history
  • Loading branch information
Aleksandr Zyabrev committed Apr 18, 2022
1 parent 5f22ecf commit 9cd1385
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions app/src/components/main/tabs/tabs.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export const Tabs = ({ config, activeTab }) => {
if (activeTab) {
setActiveTabIndex(Object.keys(config).indexOf(activeTab));
}
}, [activeTab]);
}, [activeTab, config]);

const activeTabKey = Object.keys(config)[activeTabIndex];
const activeTabInfo = config[activeTabKey];
Expand Down Expand Up @@ -91,13 +91,5 @@ Tabs.propTypes = {
};
Tabs.defaultProps = {
activeTab: '',
config: PropTypes.objectOf(
PropTypes.shape({
name: PropTypes.node,
link: PropTypes.object,
component: PropTypes.Element,
eventInfo: PropTypes.object,
mobileDisabled: PropTypes.bool,
}),
),
config: {},
};

0 comments on commit 9cd1385

Please sign in to comment.