redid a few methods to use the built-in Path class