Avatar image upload signature

This commit is contained in:
Natsumi
2021-04-02 00:28:43 +13:00
parent 21167994dd
commit 816d9749a3
6 changed files with 159 additions and 39 deletions
+3 -3
View File
@@ -153,11 +153,11 @@ namespace VRCX
}
}
if (options.TryGetValue("uploadImagePUT", out object uploadImagePUT) == true)
if (options.TryGetValue("uploadFilePUT", out object uploadImagePUT) == true)
{
request.Method = "PUT";
request.ContentType = "image/png";
var imageData = options["imageData"] as string;
request.ContentType = options["fileMIME"] as string;
var imageData = options["fileData"] as string;
byte[] sentData = Convert.FromBase64CharArray(imageData.ToCharArray(), 0, imageData.Length);
request.ContentLength = sentData.Length;
using (System.IO.Stream sendStream = request.GetRequestStream())