[mvc] Remove redundant checks (#9279)
This commit is contained in:
parent
78e00cfc31
commit
7e10a98c4f
|
|
@ -27,10 +27,6 @@ namespace Microsoft.AspNetCore.Mvc
|
|||
public FileContentResult(byte[] fileContents, string contentType)
|
||||
: this(fileContents, MediaTypeHeaderValue.Parse(contentType))
|
||||
{
|
||||
if (fileContents == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(fileContents));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
@ -80,4 +76,4 @@ namespace Microsoft.AspNetCore.Mvc
|
|||
return executor.ExecuteAsync(context, this);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,10 +27,6 @@ namespace Microsoft.AspNetCore.Mvc
|
|||
public VirtualFileResult(string fileName, string contentType)
|
||||
: this(fileName, MediaTypeHeaderValue.Parse(contentType))
|
||||
{
|
||||
if (fileName == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(fileName));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
Loading…
Reference in New Issue