title: Publish Errors on any project
body: <p>tried to publish a nopcommerce 3.9 app on my server and i got this error</p>
  
  <blockquote>
    <p>publish has encountered an error Object reference not set to an instance of an object 
    A diagnostic log has been written to following location </p>
  </blockquote>
  
  <p>Log File:</p>
  
  <blockquote>
    <p>System.NullReferenceException: Object reference not set to an instance of an object.
       at Microsoft.VisualStudio.ApplicationCapabilities.Publish.Provider.DefaultPublishTabProvider.InitializeProvider(IVsHierarchy hierarchy)
       at Microsoft.VisualStudio.ApplicationCapabilities.Publish.Provider.DefaultPublishTabProvider.d__0.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at Microsoft.VisualStudio.ApplicationCapabilities.Publish.Provider.ManagedPublishProvider.d__1.MoveNext()</p>
  </blockquote>
  
  <p>and i haven't installed SQL Server yet on my pc,haven't installed NopCommerce on my pc either and never made any changes to the source code</p>
  
  <p>Edit:it's not  duplicate of another question because in that case i would have gotten a run time error this happens when i want to publish it and the program runs just fine and my problem is in publish scenario   </p>