Grok pattern issue

I have two logs: one with loglevel field and one without it as mentioned below. can anyone help me with thescript processing both type of logs from single pattern.
the sample logs are:-
2021-09-13T23:58:22.676 [] localhost - [] :: getFormName:: Formname received is -
[DEBUG] 2021-09-13T23:58:22.676 [] localhost - [] :: getFormName:: Formname received is -