The problem is: to be able to delete a directory, the program must recursively delete all files and subdirectories present on the remote site. In order to do this, the program requests a list of files. Some servers can be configured to send the hidden files as well, but some others don't do that. In that case, the program will delete all other files, but not the hidden ones, and of course, the parent directory will not be deleted. Check if with your FTP server allows to send hidden files when a list command is received. For example, Proftpd can be configured to send hidden files in a listing: File : /etc/proftpd/proftpd.conf Modification : ListOptions "-1" replace by ListOptions "-A" #List all files except "." and ".."
In version 10, you can add a parameter to force the server to send you the listing with all hidden files. Again, the server must support this.