mirror of
https://github.com/Cysharp/UniTask.git
synced 2026-05-19 21:50:08 +00:00
Add UnityWebRequestException.ResponseHeaders #198
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
#if ENABLE_UNITYWEBREQUEST
|
#if ENABLE_UNITYWEBREQUEST
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
using UnityEngine.Networking;
|
using UnityEngine.Networking;
|
||||||
|
|
||||||
namespace Cysharp.Threading.Tasks
|
namespace Cysharp.Threading.Tasks
|
||||||
@@ -17,6 +18,7 @@ namespace Cysharp.Threading.Tasks
|
|||||||
public string Error { get; }
|
public string Error { get; }
|
||||||
public string Text { get; }
|
public string Text { get; }
|
||||||
public long ResponseCode { get; }
|
public long ResponseCode { get; }
|
||||||
|
public Dictionary<string, string> ResponseHeaders { get; }
|
||||||
|
|
||||||
string msg;
|
string msg;
|
||||||
|
|
||||||
@@ -38,6 +40,7 @@ namespace Cysharp.Threading.Tasks
|
|||||||
this.Text = dhb.text;
|
this.Text = dhb.text;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
this.ResponseHeaders = unityWebRequest.GetResponseHeaders();
|
||||||
}
|
}
|
||||||
|
|
||||||
public override string Message
|
public override string Message
|
||||||
|
|||||||
@@ -578,7 +578,7 @@ public class SandboxMain : MonoBehaviour
|
|||||||
|
|
||||||
Debug.Log("BEFORE:" + Time.frameCount);
|
Debug.Log("BEFORE:" + Time.frameCount);
|
||||||
|
|
||||||
await UniTask.Yield(PlayerLoopTiming.LastTimeUpdate);
|
// await UniTask.Yield(PlayerLoopTiming.LastTimeUpdate);
|
||||||
|
|
||||||
Debug.Log("AFTER:" + Time.frameCount);
|
Debug.Log("AFTER:" + Time.frameCount);
|
||||||
}));
|
}));
|
||||||
|
|||||||
Reference in New Issue
Block a user