diff options
| author | Bond_009 <Bond.009@outlook.com> | 2019-02-24 15:47:59 +0100 |
|---|---|---|
| committer | Bond-009 <bond.009@outlook.com> | 2019-03-07 21:42:56 +0100 |
| commit | 37ea50a572e8bd00aad39c193087228a5d3a3433 (patch) | |
| tree | 100ea9cb7986a15c50af8af57cb5d549000f206f /MediaBrowser.Api | |
| parent | 10a0d6bdba821449abfb1d48e9708ba6f3fc6a62 (diff) | |
Reduce the amount of exceptions thrown
Diffstat (limited to 'MediaBrowser.Api')
| -rw-r--r-- | MediaBrowser.Api/ApiEntryPoint.cs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/MediaBrowser.Api/ApiEntryPoint.cs b/MediaBrowser.Api/ApiEntryPoint.cs index ceff6b02e..700cbb943 100644 --- a/MediaBrowser.Api/ApiEntryPoint.cs +++ b/MediaBrowser.Api/ApiEntryPoint.cs @@ -172,6 +172,11 @@ namespace MediaBrowser.Api { var path = _config.ApplicationPaths.GetTranscodingTempPath(); + if (!Directory.Exists(path)) + { + return; + } + foreach (var file in _fileSystem.GetFilePaths(path, true)) { _fileSystem.DeleteFile(file); |
