9mario9 wrote:
Well, there are at least some people that it DOESN'T do that for them...
Look at this:
https://discussions.apple.com/thread/610210?answerId=2964173022#2964173022
That thread is 8 years old and deals with consolidation which copies files stored outside of the media folder into it, and leaves the originals where they were. That process won't empty any folders, so there will be none to clear up.
Hopefully we're agreed that iTunes is supposed to remove empty folders if, and only if, it moves the last media file out of a folder in response to a tag change, i.e. because of a change of artist name, album name, part of a compilation, media kind, or change in the folder layout option, or removes the last folder from a parent folder thereby leaving that folder empty. Note that the "Keep iTunes Media folder organized" option needs to be enabled for iTunes to respond to tag changes, and that it only applies to content inside the currently designated media folder.
Hopefully you will accept that iTunes may not be able to clear folders if there any files (hidden or otherwise) that remain in the source folder, if the security permissions on the folders don't permit the deletion via whichever security account iTunes uses for the process, or if there is third party software (e.g. AV or media management tools) that monitors file & folder activity and interrupts iTunes' actions.
Lastly iTunes will not do any subsequent housekeeping of the media folders. It either cleaned up or it didn't. If it didn't do it at the time then it can't and won't automatically tidy up later. In a similar fashion iTunes does not automatically monitor the media folders (with the exception of Automatically Add to iTunes) for new content, nor will it go back and delete files previously removed from the library if these weren't sent to the recycle bin when they were removed.
If iTunes didn't clean up as ir reorganized files then you can do so manually, or use a third party tool, or you could consolidate everything to a new media folder then delete the original (which would still be manual after a fashion, might take fewer steps but with a large library could take longer to achieve as all content has to be duplicated to the new path.)
tt2