Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/WebApiContrib.Core.Formatter.Csv/CsvInputFormatter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,9 @@ protected async Task<object> ReadStreamAsync(Type type, Stream stream)
var reader = new StreamReader(stream, _options.Encoding);

bool skipFirstLine = _options.UseSingleLineHeaderInCsv;
while (!reader.EndOfStream)
String line;
while ((line = await reader.ReadLineAsync()) != null)
{
var line = await reader.ReadLineAsync();
var values = line.Split(_options.CsvDelimiter.ToCharArray());
if (skipFirstLine)
{
Expand Down