Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception "Folder "[name]" does not exist in "/path/to/parent/[name]" when cut and paste a folder #206

Closed
sdelcroix opened this issue Mar 24, 2023 · 1 comment · Fixed by #207

Comments

@sdelcroix
Copy link
Contributor

Hi,

in TYPO3 v11, when we cut a folder and paste it in the destination folder, an exception is thrown.

#1329836110 InvalidArgumentException
Folder "test" does not exist in "/Public/Icones/test/"

The error occurs in FolderChangedEventListener.php line 73 :

$newFolder = $event->getTargetFolder()->getSubfolder($event->getTargetFolder()->getName());

There's no need to get the subfolder of the target folder 'cause getTargetFolder() already returns the new folder.
So this simple following change seems to fix the issue :

$newFolder = $event->getTargetFolder();
@FamousWolf FamousWolf linked a pull request Mar 29, 2023 that will close this issue
@FamousWolf
Copy link
Contributor

Thanks. I've implemented and tested your solution. It will be included in the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants