From ff1db0a17341345cb5d625b9a44d02981ce131bf Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Wed, 10 Apr 2013 11:56:36 -0400 Subject: resharper suggestions in controller project --- MediaBrowser.Controller/Library/ILibraryManager.cs | 5 ++--- MediaBrowser.Controller/Library/Profiler.cs | 20 ++++++++++---------- MediaBrowser.Controller/Library/TVUtils.cs | 4 +--- 3 files changed, 13 insertions(+), 16 deletions(-) (limited to 'MediaBrowser.Controller/Library') diff --git a/MediaBrowser.Controller/Library/ILibraryManager.cs b/MediaBrowser.Controller/Library/ILibraryManager.cs index a9b8f607d1..617a6c8182 100644 --- a/MediaBrowser.Controller/Library/ILibraryManager.cs +++ b/MediaBrowser.Controller/Library/ILibraryManager.cs @@ -1,6 +1,5 @@ using MediaBrowser.Controller.Entities; using MediaBrowser.Controller.IO; -using MediaBrowser.Controller.Persistence; using MediaBrowser.Controller.Resolvers; using MediaBrowser.Controller.Sorting; using MediaBrowser.Model.Entities; @@ -20,9 +19,9 @@ namespace MediaBrowser.Controller.Library event EventHandler LibraryChanged; /// - /// Raises the event. + /// Reports the library changed. /// - /// The instance containing the event data. + /// The instance containing the event data. void ReportLibraryChanged(ChildrenChangedEventArgs args); /// diff --git a/MediaBrowser.Controller/Library/Profiler.cs b/MediaBrowser.Controller/Library/Profiler.cs index 469d8ef18d..d3a754dc99 100644 --- a/MediaBrowser.Controller/Library/Profiler.cs +++ b/MediaBrowser.Controller/Library/Profiler.cs @@ -12,16 +12,16 @@ namespace MediaBrowser.Controller.Library /// /// The name /// - readonly string name; + readonly string _name; /// /// The stopwatch /// - readonly Stopwatch stopwatch; + readonly Stopwatch _stopwatch; /// /// The _logger /// - private ILogger _logger; + private readonly ILogger _logger; /// /// Initializes a new instance of the class. @@ -30,12 +30,12 @@ namespace MediaBrowser.Controller.Library /// The logger. public Profiler(string name, ILogger logger) { - this.name = name; + this._name = name; _logger = logger; - stopwatch = new Stopwatch(); - stopwatch.Start(); + _stopwatch = new Stopwatch(); + _stopwatch.Start(); } #region IDisposable Members @@ -56,17 +56,17 @@ namespace MediaBrowser.Controller.Library { if (dispose) { - stopwatch.Stop(); + _stopwatch.Stop(); string message; - if (stopwatch.ElapsedMilliseconds > 300000) + if (_stopwatch.ElapsedMilliseconds > 300000) { message = string.Format("{0} took {1} minutes.", - name, ((float)stopwatch.ElapsedMilliseconds / 60000).ToString("F")); + _name, ((float)_stopwatch.ElapsedMilliseconds / 60000).ToString("F")); } else { message = string.Format("{0} took {1} seconds.", - name, ((float)stopwatch.ElapsedMilliseconds / 1000).ToString("#0.000")); + _name, ((float)_stopwatch.ElapsedMilliseconds / 1000).ToString("#0.000")); } _logger.Info(message); } diff --git a/MediaBrowser.Controller/Library/TVUtils.cs b/MediaBrowser.Controller/Library/TVUtils.cs index d6a922ff47..6ddb1ba5fd 100644 --- a/MediaBrowser.Controller/Library/TVUtils.cs +++ b/MediaBrowser.Controller/Library/TVUtils.cs @@ -277,9 +277,7 @@ namespace MediaBrowser.Controller.Library }; } - return new List - { - }; + return new List(); } return null; } -- cgit v1.2.3