Revert "sync allows deletion of directories"

This reverts commit aa96174a674c2e80627184f61944ff31a5e814ef.