mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-27 04:24:52 +01:00
ReSharper conform to 'var' settings
This commit is contained in:
@@ -17,7 +17,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
public SubtitleTrackInfo Parse(Stream stream, CancellationToken cancellationToken)
|
||||
{
|
||||
var trackInfo = new SubtitleTrackInfo();
|
||||
List<SubtitleTrackEvent> trackEvents = new List<SubtitleTrackEvent>();
|
||||
var trackEvents = new List<SubtitleTrackEvent>();
|
||||
var eventIndex = 1;
|
||||
using (var reader = new StreamReader(stream))
|
||||
{
|
||||
|
||||
@@ -24,7 +24,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
public SubtitleTrackInfo Parse(Stream stream, CancellationToken cancellationToken)
|
||||
{
|
||||
var trackInfo = new SubtitleTrackInfo();
|
||||
List<SubtitleTrackEvent> trackEvents = new List<SubtitleTrackEvent>();
|
||||
var trackEvents = new List<SubtitleTrackEvent>();
|
||||
using (var reader = new StreamReader(stream))
|
||||
{
|
||||
string line;
|
||||
|
||||
@@ -16,7 +16,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
public SubtitleTrackInfo Parse(Stream stream, CancellationToken cancellationToken)
|
||||
{
|
||||
var trackInfo = new SubtitleTrackInfo();
|
||||
List<SubtitleTrackEvent> trackEvents = new List<SubtitleTrackEvent>();
|
||||
var trackEvents = new List<SubtitleTrackEvent>();
|
||||
|
||||
using (var reader = new StreamReader(stream))
|
||||
{
|
||||
|
||||
@@ -408,7 +408,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
/// <param name="outputPath">The output path.</param>
|
||||
/// <param name="cancellationToken">The cancellation token.</param>
|
||||
/// <returns>Task.</returns>
|
||||
/// <exception cref="System.ArgumentNullException">
|
||||
/// <exception cref="ArgumentNullException">
|
||||
/// inputPath
|
||||
/// or
|
||||
/// outputPath
|
||||
@@ -525,7 +525,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
/// <param name="outputPath">The output path.</param>
|
||||
/// <param name="cancellationToken">The cancellation token.</param>
|
||||
/// <returns>Task.</returns>
|
||||
/// <exception cref="System.ArgumentException">Must use inputPath list overload</exception>
|
||||
/// <exception cref="ArgumentException">Must use inputPath list overload</exception>
|
||||
private async Task ExtractTextSubtitle(
|
||||
string[] inputFiles,
|
||||
MediaProtocol protocol,
|
||||
@@ -734,7 +734,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
{
|
||||
if (protocol == MediaProtocol.Http)
|
||||
{
|
||||
HttpRequestOptions opts = new HttpRequestOptions()
|
||||
var opts = new HttpRequestOptions()
|
||||
{
|
||||
Url = path,
|
||||
CancellationToken = cancellationToken
|
||||
|
||||
@@ -19,8 +19,8 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
{
|
||||
cancellationToken.ThrowIfCancellationRequested();
|
||||
|
||||
TimeSpan startTime = TimeSpan.FromTicks(trackEvent.StartPositionTicks);
|
||||
TimeSpan endTime = TimeSpan.FromTicks(trackEvent.EndPositionTicks);
|
||||
var startTime = TimeSpan.FromTicks(trackEvent.StartPositionTicks);
|
||||
var endTime = TimeSpan.FromTicks(trackEvent.EndPositionTicks);
|
||||
|
||||
// make sure the start and end times are different and seqential
|
||||
if (endTime.TotalMilliseconds <= startTime.TotalMilliseconds)
|
||||
|
||||
Reference in New Issue
Block a user