Skip to content

Commit fbe5b67

Browse files
authored
Fix Elements rename and other directory destination errors (#464)
fix(): set activeDirectory when opening contextualMenu because it's used for URL making for name valiation on elements Signed-off-by: sBouzols <[email protected]>
1 parent 601027e commit fbe5b67

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/components/directory-content.jsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,11 @@ const DirectoryContent = () => {
278278
(event) => {
279279
if (event.data && event.data.uploading !== null) {
280280
if (event.data.type !== 'DIRECTORY') {
281+
if (selectedDirectory) {
282+
dispatch(
283+
setActiveDirectory(selectedDirectory.elementUuid)
284+
);
285+
}
281286
setActiveElement({
282287
hasMetadata:
283288
childrenMetadata[event.data.elementUuid] !==
@@ -313,6 +318,8 @@ const DirectoryContent = () => {
313318
childrenMetadata,
314319
contextualMixPolicies.BIG,
315320
contextualMixPolicy,
321+
dispatch,
322+
selectedDirectory,
316323
]
317324
);
318325

0 commit comments

Comments
 (0)