Fix tab names [again]

Summary: child.hasOwnProperty -> child.props.hasOwnProperty for tabs

Reviewed By: udat

Differential Revision: D37751552

fbshipit-source-id: 78015bbc185387587ce3644c959596cf0a661ddf
This commit is contained in:
James Wysynski
2022-07-11 06:40:31 -07:00
committed by Facebook GitHub Bot
parent 0e11eaabb3
commit 5551cf3bb2

View File

@@ -30,13 +30,13 @@ export function Tabs({
return;
}
const tabKey =
(child.hasOwnProperty('tabKey') &&
(child.props.hasOwnProperty('tabKey') &&
typeof child.props.tabKey === 'string' &&
child.props.tabKey) ||
(child.hasOwnProperty('tab') &&
(child.props.hasOwnProperty('tab') &&
typeof child.props.tab === 'string' &&
child.props.tab) ||
(child.hasOwnProperty('key') &&
(child.props.hasOwnProperty('key') &&
typeof child.props.key === 'string' &&
child.props.key) ||
`tab_${idx}`;