Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix #12461.
After .NET 4.5 .NET Framework has changed the System.ComponentModel.Composition ReflectionModelServices.IsExportFactoryImportDefinition to not throw.

Updating this to match the .NET Framework behavior.
  • Loading branch information
KirillOsenkov authored and marek-safar committed Jan 17, 2019
1 parent 1dee626 commit 725ba2a
Showing 1 changed file with 0 additions and 8 deletions.
Expand Up @@ -110,14 +110,6 @@ public static bool IsExportFactoryImportDefinition(ImportDefinition importDefini
{
Requires.NotNull(importDefinition, "importDefinition");

ReflectionImportDefinition reflectionImportDefinition = importDefinition as ReflectionImportDefinition;
if (reflectionImportDefinition == null)
{
throw new ArgumentException(
string.Format(CultureInfo.CurrentCulture, Strings.ReflectionModel_InvalidImportDefinition, importDefinition.GetType()),
"importDefinition");
}

return (importDefinition is IPartCreatorImportDefinition);
}

Expand Down

0 comments on commit 725ba2a

Please sign in to comment.