Hi,
You said:
I installed the plugin .pdf invoices and when I order , the invoice is attached.
I suppose that you meant:
I installed the plugin .pdf invoices and when I order , the invoice is NOT attached.
right ?
In that case, I suppose that the problem is that you entered something in the "statuses for email attachment" setting of the plugin.
What you entered is wrong. The confirmed status doesn't have an uppercase letter in the database. Only in the English translation. So you should actually write it without the uppercase or it won't match.
Also, you can actually leave that field empty and the system will automatically use the statuses configured in the HikaShop configuration.