refactored invoicng making clear interface