diff --git a/lib/form_filler.mjs b/lib/form_filler.mjs index c666f70..8d92776 100644 --- a/lib/form_filler.mjs +++ b/lib/form_filler.mjs @@ -573,7 +573,12 @@ Answer:`; if (radios[0]) await radios[0].click().catch(() => {}); } else if (snap.resumeRadios.length === 0 && snap.hasFileInput && resumePath) { const fileInput = await container.$('input[type="file"]'); - if (fileInput) await fileInput.setInputFiles(resumePath).catch(() => {}); + if (fileInput) { + // Skip if the file input doesn't accept our resume format (e.g. image-only uploads) + const accept = await fileInput.getAttribute('accept').catch(() => '') || ''; + const acceptsResume = !accept || /pdf|doc|docx/i.test(accept); + if (acceptsResume) await fileInput.setInputFiles(resumePath).catch(() => {}); + } } // --- Inputs (text/number/url/email/tel) ---