moved getPath() to cache