diff --git a/Src/Newtonsoft.Json/Serialization/DefaultContractResolver.cs b/Src/Newtonsoft.Json/Serialization/DefaultContractResolver.cs index 772eb5c0..05e2bac8 100644 --- a/Src/Newtonsoft.Json/Serialization/DefaultContractResolver.cs +++ b/Src/Newtonsoft.Json/Serialization/DefaultContractResolver.cs @@ -193,10 +193,7 @@ namespace Newtonsoft.Json.Serialization /// The contract for a given type. public virtual JsonContract ResolveContract(Type type) { - if (type == null) - { - throw new ArgumentNullException(nameof(type)); - } + ValidationUtils.ArgumentNotNull(type, nameof(type)); return _contractCache.Get(type); }