title: Why is this InvalidCastException: Specified cast is not valid error?
body: <p>It refers me the bellow line with the above error. Would appreciate your help.</p>
  <p>'var model = await _context.EvaluationRisques.ToListAsync();'</p>
  <p>Controller:</p>
  <pre><code> // GET: EvaluationRisques
          [Authorize(Roles = &quot;Administrateur, Modificateur, Lecteur&quot;)]
          public async Task&lt;IActionResult&gt; Index()
          {
              var model = await _context.EvaluationRisques.ToListAsync();
              var vm = _mapper.Map&lt;List&lt;EvaluationRisquesViewModel&gt;&gt;(model);
              return View(vm);
          }
  </code></pre>