From 08a897d7b07aca6b6495939fa0a407dd81229944 Mon Sep 17 00:00:00 2001 From: Kenneth Hsu Date: Sun, 27 May 2018 13:17:30 -0700 Subject: Remove redundant calls to ToString. --- Duplicati/Library/Backend/Rclone/Rclone.cs | 6 +++--- Duplicati/Library/Backend/SharePoint/SharePointBackend.cs | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'Duplicati/Library/Backend') diff --git a/Duplicati/Library/Backend/Rclone/Rclone.cs b/Duplicati/Library/Backend/Rclone/Rclone.cs index b16b48a0f..a11f7bbc7 100644 --- a/Duplicati/Library/Backend/Rclone/Rclone.cs +++ b/Duplicati/Library/Backend/Rclone/Rclone.cs @@ -172,13 +172,13 @@ namespace Duplicati.Library.Backend if (errorBuilder.ToString().Contains(RCLONE_ERROR_CONFIG_NOT_FOUND)) { - throw new Exception(String.Format("Missing config file? {0}", errorBuilder.ToString())); + throw new Exception(String.Format("Missing config file? {0}", errorBuilder)); } if (errorBuilder.Length > 0) { throw new Exception(errorBuilder.ToString()); } - Console.Error.WriteLine(errorBuilder.ToString()); + Console.Error.WriteLine(errorBuilder); return outputBuilder.ToString(); } @@ -208,7 +208,7 @@ namespace Duplicati.Library.Backend foreach (JObject item in array) { #if DEBUG - Console.Error.WriteLine(item.ToString()); + Console.Error.WriteLine(item); #endif FileEntry fe = new FileEntry( item.GetValue("Name").Value(), diff --git a/Duplicati/Library/Backend/SharePoint/SharePointBackend.cs b/Duplicati/Library/Backend/SharePoint/SharePointBackend.cs index cef7ba6dd..2e0bad9c3 100644 --- a/Duplicati/Library/Backend/SharePoint/SharePointBackend.cs +++ b/Duplicati/Library/Backend/SharePoint/SharePointBackend.cs @@ -431,7 +431,7 @@ namespace Duplicati.Library.Backend { var req = m_parent.CreateWebRequestExecutor(context, requestUrl); if (string.IsNullOrWhiteSpace(req.WebRequest.UserAgent)) - req.WebRequest.UserAgent = "Duplicati OD4B v" + System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString(); + req.WebRequest.UserAgent = "Duplicati OD4B v" + System.Reflection.Assembly.GetExecutingAssembly().GetName().Version; return req; } } -- cgit v1.2.3