Before generating invoices