Form with upload incorrect file show the messeage

I encountered an exception and found no solution anywhere.

Forms work in “process:” with “message:” and it works great, except when I upload a mismatched file to the drag and drop box, for example “filesize: 1” and I upload a 1.5 Mb file.

Yes, the form crosses the file and after running it I can read that the file is too large to upload, but if I do not delete the file from the field and send the form, it will be processed and even if it is not sent a message about successful submission.

So how do I solve the problem with the command upload field?
Something like “message_incorrect:”
Has anyone solved it?

Thank you for your time guys!