fix duplicate name/key render warning
This commit is contained in:
parent
e29a777a9f
commit
1107779a63
@ -39,7 +39,7 @@ const StudyListTableRow = props => {
|
||||
|
||||
return (
|
||||
<td
|
||||
key={name}
|
||||
key={index}
|
||||
className={classnames(
|
||||
'px-4 py-2 text-base truncate',
|
||||
{ 'border-b border-secondary-light': !isExpanded },
|
||||
|
||||
@ -164,6 +164,7 @@ function StudyListContainer({ history, data: studies }) {
|
||||
};
|
||||
const tableDataSource = studies
|
||||
// TOOD: Move sort to DataSourceWrapper?
|
||||
// TODO: MOTIVATION, this is triggered on every render, even if list/sort does not change
|
||||
.sort((s1, s2) => {
|
||||
const noSortApplied = sortBy === '' || !sortBy;
|
||||
const sortModifier = sortDirection === 'descending' ? 1 : -1;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user