ECMS-5757 check if selected folder is empty, then return empty result an...

...d do not query