aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs
diff options
context:
space:
mode:
authorJoshua M. Boniface <joshua@boniface.me>2018-12-30 17:29:02 -0500
committerGitHub <noreply@github.com>2018-12-30 17:29:02 -0500
commit1f02cf4b7e13c932bc30968cbb74b71885fd3eb7 (patch)
tree2fbf2e570340765abd40b5ad8e491f1f212699c0 /MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs
parent7ad023143062c1995178e5700961b553822bd5af (diff)
parent4c95aee52eda793d1e013164cc0fde9eb609f894 (diff)
Merge pull request #285 from Bond-009/logging
Use Serilog to handle logging
Diffstat (limited to 'MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs')
-rw-r--r--MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs14
1 files changed, 7 insertions, 7 deletions
diff --git a/MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs b/MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs
index e21292cbd..d2cf7f395 100644
--- a/MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs
+++ b/MediaBrowser.MediaEncoding/Encoder/FontConfigLoader.cs
@@ -10,7 +10,7 @@ using MediaBrowser.Common.Net;
using MediaBrowser.Common.Progress;
using MediaBrowser.Controller.IO;
using MediaBrowser.Model.IO;
-using MediaBrowser.Model.Logging;
+using Microsoft.Extensions.Logging;
using MediaBrowser.Model.Net;
namespace MediaBrowser.MediaEncoding.Encoder
@@ -72,12 +72,12 @@ namespace MediaBrowser.MediaEncoding.Encoder
catch (HttpException ex)
{
// Don't let the server crash because of this
- _logger.ErrorException("Error downloading ffmpeg font files", ex);
+ _logger.LogError(ex, "Error downloading ffmpeg font files");
}
catch (Exception ex)
{
// Don't let the server crash because of this
- _logger.ErrorException("Error writing ffmpeg font files", ex);
+ _logger.LogError(ex, "Error writing ffmpeg font files");
}
}
@@ -103,7 +103,7 @@ namespace MediaBrowser.MediaEncoding.Encoder
catch (IOException ex)
{
// Log this, but don't let it fail the operation
- _logger.ErrorException("Error copying file", ex);
+ _logger.LogError(ex, "Error copying file");
}
}
@@ -127,7 +127,7 @@ namespace MediaBrowser.MediaEncoding.Encoder
catch (Exception ex)
{
// The core can function without the font file, so handle this
- _logger.ErrorException("Failed to download ffmpeg font file from {0}", ex, url);
+ _logger.LogError(ex, "Failed to download ffmpeg font file from {url}", url);
}
}
@@ -145,12 +145,12 @@ namespace MediaBrowser.MediaEncoding.Encoder
catch (IOException ex)
{
// Log this, but don't let it fail the operation
- _logger.ErrorException("Error deleting temp file {0}", ex, tempFile);
+ _logger.LogError(ex, "Error deleting temp file {path}", tempFile);
}
}
private void Extract7zArchive(string archivePath, string targetPath)
{
- _logger.Info("Extracting {0} to {1}", archivePath, targetPath);
+ _logger.LogInformation("Extracting {ArchivePath} to {TargetPath}", archivePath, targetPath);
_zipClient.ExtractAllFrom7z(archivePath, targetPath, true);
}