Skip to content
This repository was archived by the owner on Nov 20, 2018. It is now read-only.

Commit 51a1cab

Browse files
committed
Prefer filename* when available
1 parent 88daf58 commit 51a1cab

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Microsoft.AspNetCore.Http/Features/FormFeature.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,9 @@ private async Task<IFormCollection> InnerReadFormAsync(CancellationToken cancell
181181
await section.Body.DrainAsync(cancellationToken);
182182

183183
var name = HeaderUtilities.RemoveQuotes(contentDisposition.Name) ?? string.Empty;
184-
var fileName = HeaderUtilities.RemoveQuotes(contentDisposition.FileName) ?? string.Empty;
184+
var fileName = HeaderUtilities.RemoveQuotes(contentDisposition.FileNameStar) ??
185+
HeaderUtilities.RemoveQuotes(contentDisposition.FileName) ??
186+
string.Empty;
185187

186188
FormFile file;
187189
if (section.BaseStreamOffset.HasValue)

0 commit comments

Comments
 (0)