title: How do I attach ASP.net's default Application User to application specific model?
body: <p>This is my application specific model</p>
  
  <pre><code>  public class Employer
      {
          public int ID { get; set; }
          public string EmployerName { get; set; }
          public virtual ApplicationUser User { get; set; }
  
  
      }
  </code></pre>
  
  <p>This is asp.net's default setup for creation of this model</p>
  
  <pre><code>     [HttpPost]
      [ValidateAntiForgeryToken]
      public async Task&lt;IActionResult&gt; Create([Bind("ID,EmployerName")] Employer employer)
      {
          if (ModelState.IsValid)
          {
  
             //was hoping solution would be as easy as..
             //employer.User = HttpContext.User;
             //but that is not working neither is anything else I find
  
              _context.Add(employer);
              await _context.SaveChangesAsync();
              return RedirectToAction("Index");
          }
          return View(employer);
      }
  </code></pre>
  
  <p>When the Employer model is created no ApplicationUser is set to it. How do I go about getting the user from the current session and setting it to a model instance on creation. I am new to the asp.net framework so forgive me for my lack of understanding. Thank You so much for your reading over this.</p>