[Fixes #1628] Avoid stomping on an existing FileProvider

Respects the existing one if it's there.
This commit is contained in:
Javier Calvarro Nelson 2018-02-14 13:41:31 -08:00
parent bbad5d601d
commit b4cf3ed071
1 changed files with 1 additions and 1 deletions

View File

@ -59,7 +59,7 @@ namespace Microsoft.AspNetCore.Identity.UI
throw new InvalidOperationException("Missing FileProvider.");
}
options.FileProvider = Environment.WebRootFileProvider;
options.FileProvider = options.FileProvider ?? Environment.WebRootFileProvider;
// Add our provider
var filesProvider = new ManifestEmbeddedFileProvider(GetType().Assembly, "wwwroot");