passport refactor