Refactor account()