fixes bug of paths with space