Remove "Plex Versions" folder if there is nothing inside it.

Hi there,

I have been fiddling around with the new Media Optimizer. Thanks for that awesome feature! I have one addition, to make it perfect:

After an Optimized Version is deleted from the Plex Library, it will be deleted from the data store as well. So far so good. I would now be nice for Plex to check if there is any file in the “Plex Versions” folder. If not, this folder is just messing up my perfect file structure, and can be deleted.

So simple in code:

on ( optimizeVersion.delete()) 
    if ( plexVersionsFolder.isEmpty() )
          plexVersionsFolder.delete()

Thanks!

Cheers,
Hauke