refactor : 重构代码
This commit is contained in:
+1
-1
@@ -76,7 +76,7 @@ namespace YooAsset
|
||||
else
|
||||
{
|
||||
if (string.IsNullOrEmpty(_args.FileHash))
|
||||
throw new YooInternalException("File hash is null or empty!");
|
||||
throw new YooInternalException("File hash is null or empty.");
|
||||
|
||||
// 使用 Unity 缓存
|
||||
// 说明:The file hash defining the version of the asset bundle.
|
||||
|
||||
+2
-2
@@ -99,7 +99,7 @@ namespace YooAsset
|
||||
if (_webRequest == null)
|
||||
{
|
||||
Status = EDownloadRequestStatus.Failed;
|
||||
Error = $"[{GetType().Name}] Created web request is null!";
|
||||
Error = $"[{GetType().Name}] Created web request is null.";
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -226,7 +226,7 @@ namespace YooAsset
|
||||
protected void ApplyRequestOptions(int timeout, int watchdogTime, Dictionary<string, string> headers)
|
||||
{
|
||||
if (_webRequest == null)
|
||||
throw new YooInternalException("Web request is null!");
|
||||
throw new YooInternalException("Web request is null.");
|
||||
|
||||
// 设置看门狗超时时间
|
||||
_watchdogTime = watchdogTime;
|
||||
|
||||
@@ -57,7 +57,7 @@ namespace YooAsset
|
||||
#elif UNITY_STANDALONE_LINUX
|
||||
url = StringUtility.Format("file:///root/{0}", path);
|
||||
#else
|
||||
throw new System.NotSupportedException($"[{nameof(DownloadSystemHelper.ConvertToWWWPath)}] Platform '{UnityEngine.Application.platform}' is not supported!");
|
||||
throw new System.NotSupportedException($"[{nameof(DownloadSystemHelper.ConvertToWWWPath)}] Platform '{UnityEngine.Application.platform}' is not supported.");
|
||||
#endif
|
||||
|
||||
// For some special cases when users have special characters in their devices, url paths can not be identified correctly.
|
||||
|
||||
Reference in New Issue
Block a user