title: "Missing credentials" with PassportJS when I put enctype="multipart/form-data" and an input[type="file"]
body: <h1>THE PROBLEM</h1>
  
  <p>I've got a problem, when I use enctype="multipart/form-data" to my form (with an upload (.jpg/.png, etc.)) and I sumbit it, my flash displays "Missing credentials", without precisions. So how do I fix this ?</p>
  
  <h1>What I've tried</h1>
  
  <p>I searched solutions, but no one answered my problem. So I tried to resolve this, during 1-2 hours. I've found nothing. I asked too in another forum (alsacreations.com, if you know)</p>
  
  <p>What I know, it is NOT a problem with my config/passport.js because otherwise, in my console, I would have logs.</p>
  
  <h1>Some code</h1>
  
  <pre><code>[2] GET /api/auth/user 304 0.621 ms - -
  [2] GET /api/auth/user 304 0.816 ms - -
  [2] GET /favicon.ico 200 0.072 ms - 2780
  [2] GET /assets/dist/app.js 304 1.433 ms - -
  [2] GET /signup 304 2.842 ms - -
  [2] POST /api/auth/user 200 5.250 ms - 2
  [2] POST /signup 302 0.951 ms - 58
  [2] GET /signup 200 3.036 ms - 3596
  [2] GET /assets/styles/main-css.css 304 0.919 ms - -
  [2] GET /assets/dist/main-js.js 304 2.542 ms - -
  [2] GET /assets/dist/app.js 304 1.797 ms - -
  [2] GET /assets/config/config-en.json 304 0.720 ms - -
  [2] GET /assets/dist/manifest.json 304 0.584 ms - -
  [2] GET /api/auth/user 200 0.529 ms - 5
  [2] GET /api/auth/user 304 1.049 ms - -
  [2] GET /assets/dist/app.js 304 0.994 ms - -
  [2] GET /signup 200 4.576 ms - 3376
  </code></pre>
  
  <p>As you see it there's no log...</p>
  
  <h1>Let's the demo!</h1>
  
  <p><a href="https://forum.alsacreations.com/upload/1559134328-67719-alsa.png" rel="nofollow noreferrer">https://forum.alsacreations.com/upload/1559134328-67719-alsa.png</a></p>
  
  <ul>
  <li>I've a form (with enctype="multipart/form-data", etc.)</li>
  </ul>
  
  <p><a href="https://forum.alsacreations.com/upload/1559134431-67719-alsa.png" rel="nofollow noreferrer">https://forum.alsacreations.com/upload/1559134431-67719-alsa.png</a></p>
  
  <ul>
  <li>I upload my picture (as it happens an avatar)</li>
  </ul>
  
  <p><a href="https://forum.alsacreations.com/upload/1559134534-67719-alsa.png" rel="nofollow noreferrer">https://forum.alsacreations.com/upload/1559134534-67719-alsa.png</a></p>
  
  <ul>
  <li>BUT (else it'll be too easy...)
  When I upload it, I've got this message ("Missing credentials"), is there any callback that I've not caught? (I wanna have more informations)</li>
  </ul>
  
  <p>Thanks for your help.</p>
  
  <p>(Sorry I can't place images, I'm under the 10 points of reputations, lol)</p>