Use list key provided by react-virtualized in UserList
This commit is contained in:
parent
6a9942a655
commit
007dd3fe63
File diff suppressed because one or more lines are too long
@ -14,14 +14,13 @@ export default class UserList extends PureComponent {
|
|||||||
|
|
||||||
listRef = el => { this.list = el; };
|
listRef = el => { this.list = el; };
|
||||||
|
|
||||||
renderUser = ({ index, style }) => {
|
renderUser = ({ index, style, key }) => {
|
||||||
const { users, tab, openPrivateChat, select } = this.props;
|
const { users, tab, openPrivateChat, select } = this.props;
|
||||||
const user = users.get(index);
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<UserListItem
|
<UserListItem
|
||||||
key={user.nick}
|
key={key}
|
||||||
user={user}
|
user={users.get(index)}
|
||||||
tab={tab}
|
tab={tab}
|
||||||
openPrivateChat={openPrivateChat}
|
openPrivateChat={openPrivateChat}
|
||||||
select={select}
|
select={select}
|
||||||
|
Loading…
Reference in New Issue
Block a user