Browse Source

Remove DirectoryExists

Krzysztof Krysiński 3 weeks ago
parent
commit
643f70a995
1 changed files with 2 additions and 8 deletions
  1. 2 8
      src/PixiEditor.AnimationRenderer.FFmpeg/FFMpegRenderer.cs

+ 2 - 8
src/PixiEditor.AnimationRenderer.FFmpeg/FFMpegRenderer.cs

@@ -34,10 +34,7 @@ public class FFMpegRenderer : IAnimationRenderer
         }
         }
 
 
         string tempPath = Path.Combine(Path.GetTempPath(), "PixiEditor", "Rendering");
         string tempPath = Path.Combine(Path.GetTempPath(), "PixiEditor", "Rendering");
-        if (!Directory.Exists(tempPath))
-        {
-            Directory.CreateDirectory(tempPath);
-        }
+        Directory.CreateDirectory(tempPath);
 
 
         string paletteTempPath = Path.Combine(tempPath, "palette.png");
         string paletteTempPath = Path.Combine(tempPath, "palette.png");
 
 
@@ -99,10 +96,7 @@ public class FFMpegRenderer : IAnimationRenderer
         }
         }
 
 
         string tempPath = Path.Combine(Path.GetTempPath(), "PixiEditor", "Rendering");
         string tempPath = Path.Combine(Path.GetTempPath(), "PixiEditor", "Rendering");
-        if (!Directory.Exists(tempPath))
-        {
-            Directory.CreateDirectory(tempPath);
-        }
+        Directory.CreateDirectory(tempPath);
 
 
         string paletteTempPath = Path.Combine(tempPath, "palette.png");
         string paletteTempPath = Path.Combine(tempPath, "palette.png");