Skip to content

Commit

Permalink
Merge pull request #99 from MattHartz/UploadVideoFix
Browse files Browse the repository at this point in the history
Issue #96 Fix
  • Loading branch information
mfilippov authored Sep 27, 2017
2 parents e483dc2 + 5756aea commit ccab9ea
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/VimeoDotNet/VimeoClient_Upload.cs
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,8 @@ private async Task<IApiRequest> GenerateFileStreamRequest(IBinaryContent fileCon
{
var startIndex = fileContent.Data.CanSeek ? fileContent.Data.Position : written;
var endIndex = Math.Min(startIndex + chunkSize.Value, fileContent.Data.Length);
request.Body = new ByteArrayContent(await fileContent.ReadAsync(startIndex, endIndex), (int)startIndex, (int)endIndex);
var byteArray = await fileContent.ReadAsync(startIndex, endIndex);
request.Body = new ByteArrayContent(byteArray, 0, byteArray.Length);
}
else
{
Expand Down

0 comments on commit ccab9ea

Please sign in to comment.