title: Getting Error: Not all code paths return a value
body: <p>I am new to mvc C# and am stuck. Please advise on how to fix this. I'm getting the error on Add. When I hover over the red squiggly line it says "Not all code paths return a value"</p>
  
  <pre><code>    public ActionResult Add(ShapeInputModel dto, FormCollection collection)
      {
  
          var model = new GeoRegions();
  
          if (TryUpdateModel(model))
          {
  
  
              var destinationFolder = Server.MapPath("/App_Data/KML");
              var postedFile = dto.Shape;
  
              if (postedFile != null)
              {
                  var fileName = Path.GetFileName(postedFile.FileName);
                  var path = Path.Combine(destinationFolder, fileName);
                  postedFile.SaveAs(path);
  
                  //Save to Database
                  Db.AddGeoRegions(model);
                  return RedirectToAction("Index");
  
              }
  
              return View();
  
          }
      }
  </code></pre>