No invoice number in emailed invoices

Hi,

I’ve noticed that with the “Generate the invoice number for draft invoices option set” to “No”, invoice numbers are generated after the email is sent to customer. So the customer would receive an invoice without the invoice number. However on the second email, invoice number is appeared as normal. I think when the actual send button is clicked on the send email screen, it should be first generate the invoice number and save the invoice before sending out the email