fix(fe/files_panel): breadcrumb part key can not be same

This commit is contained in:
hexxa 2022-01-12 19:39:24 +08:00 committed by Hexxa
parent 16ff18555a
commit dfd691c9f0

View file

@ -735,7 +735,7 @@ export class FilesPanel extends React.Component<Props, State, {}> {
const breadcrumb = this.props.filesInfo.dirPath.map(
(pathPart: string, key: number) => {
return (
<span key={pathPart}>
<span key={`${pathPart}-${key}`}>
<a
onClick={() =>
this.chdir(this.props.filesInfo.dirPath.slice(0, key + 1))