Skip to content

Commit

Permalink
Fix build break (#56179)
Browse files Browse the repository at this point in the history
Disable the warning until a proper fix can be made.

See #56178
  • Loading branch information
eerhardt authored Jul 22, 2021
1 parent 0a3e317 commit 77d23f0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/libraries/Microsoft.Extensions.Hosting/src/HostBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,9 @@ private void CreateHostingEnvironment()
_hostingEnvironment.ApplicationName = Assembly.GetEntryAssembly()?.GetName().Name;
}

#pragma warning disable CA1416 // 'PhysicalFileProvider' is unsupported on: 'browser' https://github.com/dotnet/runtime/issues/56178
_hostingEnvironment.ContentRootFileProvider = _defaultProvider = new PhysicalFileProvider(_hostingEnvironment.ContentRootPath);
#pragma warning restore CA1416 // 'PhysicalFileProvider' is unsupported on: 'browser'
}

private string ResolveContentRootPath(string contentRootPath, string basePath)
Expand Down

0 comments on commit 77d23f0

Please sign in to comment.