make sure that we only remove file/folder shares
fix escaping