Fixing plfs-mdhim bugs
Merged Alfred's changes