Replaced code in invoice_split to own method