Bug in FileSystem API, removing directories