Use ApplicationBasePath instead of entry assembly to locate reference

assemblies.
This commit is contained in:
Pranav K 2016-02-11 22:29:20 -08:00
parent 5a257a7107
commit 59e87f497f

View file

@ -25,7 +25,7 @@ namespace Microsoft.Extensions.DependencyModel
string basePath;
var appBase = Path.GetDirectoryName(entryAssembly.Location);
var appBase = PlatformServices.Default.Application.ApplicationBasePath;
var refsDir = Path.Combine(appBase, "refs");
var hasRefs = Directory.Exists(refsDir);
var isProject = string.Equals(LibraryType, "project", StringComparison.OrdinalIgnoreCase);