ui(admin): too many changes, not enough commits
This commit is contained in:
parent
bca2338863
commit
8aa9641ec2
44 changed files with 1955 additions and 334 deletions
|
@ -30,10 +30,10 @@ const RenameFileModal = ({ files, useMoveTerminology, ...props }: OwnProps) => {
|
|||
if (files.length === 1) {
|
||||
if (!useMoveTerminology && len === 1) {
|
||||
// Rename the file within this directory.
|
||||
mutate(data => data.map(f => f.name === files[0] ? { ...f, name } : f), false);
|
||||
mutate(data => data!.map(f => f.name === files[0] ? { ...f, name } : f), false);
|
||||
} else if ((useMoveTerminology || len > 1)) {
|
||||
// Remove the file from this directory since they moved it elsewhere.
|
||||
mutate(data => data.filter(f => f.name !== files[0]), false);
|
||||
mutate(data => data!.filter(f => f.name !== files[0]), false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue