handle no subs setting

This commit is contained in:
Luke Pulverenti 2016-03-04 23:16:55 -05:00
parent 21ebd05a0e
commit ca83644e1c

View File

@ -17,6 +17,7 @@ using System.Threading;
using System.Threading.Tasks;
using CommonIO;
using MediaBrowser.Common.IO;
using MediaBrowser.Model.Configuration;
namespace MediaBrowser.Server.Implementations.Library
{
@ -276,7 +277,7 @@ namespace MediaBrowser.Server.Implementations.Library
private void SetDefaultSubtitleStreamIndex(MediaSourceInfo source, UserItemData userData, User user)
{
if (userData.SubtitleStreamIndex.HasValue && user.Configuration.RememberSubtitleSelections)
if (userData.SubtitleStreamIndex.HasValue && user.Configuration.RememberSubtitleSelections && user.Configuration.SubtitleMode != SubtitlePlaybackMode.None)
{
var index = userData.SubtitleStreamIndex.Value;
// Make sure the saved index is still valid