The problem seems to be with the filecatalog( function in the code of the copyfolder custom statement. It apparently doesn’t catalog packages. I tried putting an rtfd in a folder that had some Panorama X databases, and some image files. Only the images were catalogued by filecatalog(. rtfd documents are also packages.
The problem seems to be with the filecatalog( function
Bingo! We have a winner. Rather amazing that neither myself nor anyone else has noticed this in six years.
Oh wait, it actually WAS noticed six years ago. I’ve just now marked this old bug report as a duplicate since I put a lot more information into the new bug report.