Refactor billing