refactor: the same unityPath can be used for three of them

This commit is contained in:
0b5vr 2023-02-20 17:02:14 +09:00
parent 3c390fe0f3
commit bf69c34cfc

View File

@ -17,11 +17,13 @@ namespace VRM
{
foreach (string path in importedAssets)
{
if (!UnityPath.FromUnityPath(path).IsFileExists) {
var unityPath = UnityPath.FromUnityPath(path);
if (!unityPath.IsFileExists) {
continue;
}
if (UnityPath.FromUnityPath(path).IsStreamingAsset)
if (unityPath.IsStreamingAsset)
{
Debug.LogFormat("Skip StreamingAssets: {0}", path);
continue;
@ -32,7 +34,7 @@ namespace VRM
{
try
{
ImportVrm(UnityPath.FromUnityPath(path));
ImportVrm(unityPath);
}
catch (NotVrm0Exception)
{