Add pathname method