Merge pull request #1725 from MediaBrowser/dev

fix DeviceDiscovery
pull/702/head
Luke 9 years ago
commit 21356d10e3

@ -1186,23 +1186,6 @@ namespace MediaBrowser.Controller.Entities
return false; return false;
} }
private string _userDataKey;
/// <summary>
/// Gets the user data key.
/// </summary>
/// <returns>System.String.</returns>
public string GetUserDataKey()
{
if (string.IsNullOrWhiteSpace(_userDataKey))
{
var key = GetUserDataKeys().First();
_userDataKey = key;
return key;
}
return _userDataKey;
}
public virtual List<string> GetUserDataKeys() public virtual List<string> GetUserDataKeys()
{ {
var list = new List<string>(); var list = new List<string>();
@ -1229,7 +1212,6 @@ namespace MediaBrowser.Controller.Entities
public void AfterMetadataRefresh() public void AfterMetadataRefresh()
{ {
_sortName = null; _sortName = null;
_userDataKey = null;
} }
/// <summary> /// <summary>
@ -2074,7 +2056,6 @@ namespace MediaBrowser.Controller.Entities
/// </summary> /// </summary>
public virtual bool BeforeMetadataRefresh() public virtual bool BeforeMetadataRefresh()
{ {
_userDataKey = null;
_sortName = null; _sortName = null;
var hasChanges = false; var hasChanges = false;

@ -8,12 +8,6 @@ namespace MediaBrowser.Controller.Entities
/// </summary> /// </summary>
public interface IHasUserData : IHasId public interface IHasUserData : IHasId
{ {
/// <summary>
/// Gets the user data key.
/// </summary>
/// <returns>System.String.</returns>
string GetUserDataKey();
List<string> GetUserDataKeys(); List<string> GetUserDataKeys();
/// <summary> /// <summary>

@ -125,11 +125,6 @@ namespace MediaBrowser.Dlna.Ssdp
args.EndPoint = endPoint; args.EndPoint = endPoint;
args.LocalEndPoint = new IPEndPoint(localIp, 0); args.LocalEndPoint = new IPEndPoint(localIp, 0);
if (_ssdpHandler.IgnoreMessage(args, true))
{
return;
}
_ssdpHandler.LogMessageReceived(args, true); _ssdpHandler.LogMessageReceived(args, true);
TryCreateDevice(args); TryCreateDevice(args);

@ -10,6 +10,7 @@ using MediaBrowser.Model.Logging;
using System; using System;
using System.Collections.Concurrent; using System.Collections.Concurrent;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq;
using System.Threading; using System.Threading;
using System.Threading.Tasks; using System.Threading.Tasks;
@ -199,22 +200,22 @@ namespace MediaBrowser.Server.Implementations.Library
public UserItemData GetUserData(IHasUserData user, IHasUserData item) public UserItemData GetUserData(IHasUserData user, IHasUserData item)
{ {
return GetUserData(user.Id, item.GetUserDataKey()); return GetUserData(user.Id, item.GetUserDataKeys().First());
} }
public UserItemData GetUserData(string userId, IHasUserData item) public UserItemData GetUserData(string userId, IHasUserData item)
{ {
return GetUserData(userId, item.GetUserDataKey()); return GetUserData(userId, item.GetUserDataKeys().First());
} }
public UserItemData GetUserData(Guid userId, IHasUserData item) public UserItemData GetUserData(Guid userId, IHasUserData item)
{ {
return GetUserData(userId, item.GetUserDataKey()); return GetUserData(userId, item.GetUserDataKeys().First());
} }
public UserItemDataDto GetUserDataDto(IHasUserData item, User user) public UserItemDataDto GetUserDataDto(IHasUserData item, User user)
{ {
var userData = GetUserData(user.Id, item.GetUserDataKey()); var userData = GetUserData(user.Id, item.GetUserDataKeys().First());
var dto = GetUserItemDataDto(userData); var dto = GetUserItemDataDto(userData);
item.FillUserDataDtoValues(dto, userData, user); item.FillUserDataDtoValues(dto, userData, user);

@ -345,7 +345,8 @@ namespace MediaBrowser.Server.Implementations.Sync
if (!folder.IsPreSorted) if (!folder.IsPreSorted)
{ {
items = items.OrderBy(i => i.SortName).ToArray(); items = _libraryManager.Sort(items, user, new[] { ItemSortBy.SortName }, SortOrder.Ascending)
.ToArray();
} }
return items; return items;

@ -158,7 +158,7 @@ namespace MediaBrowser.ServerApplication.Native
info.FFMpegFilename = "ffmpeg.exe"; info.FFMpegFilename = "ffmpeg.exe";
info.FFProbeFilename = "ffprobe.exe"; info.FFProbeFilename = "ffprobe.exe";
info.Version = "20160508"; info.Version = "20160410";
info.ArchiveType = "7z"; info.ArchiveType = "7z";
info.IsEmbedded = false; info.IsEmbedded = false;
info.DownloadUrls = GetDownloadUrls(); info.DownloadUrls = GetDownloadUrls();
@ -214,14 +214,14 @@ namespace MediaBrowser.ServerApplication.Native
case Architecture.X86_X64: case Architecture.X86_X64:
return new[] return new[]
{ {
"https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/windows/ffmpeg-20160508-win64.7z", "https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/windows/ffmpeg-20160410-win64.7z",
"https://ffmpeg.zeranoe.com/builds/win64/static/ffmpeg-20160508-git-caee88d-win64-static.7z" "https://ffmpeg.zeranoe.com/builds/win64/static/ffmpeg-20160409-git-0c90b2e-win64-static.7z"
}; };
case Architecture.X86: case Architecture.X86:
return new[] return new[]
{ {
"https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/windows/ffmpeg-20160508-win32.7z", "https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/windows/ffmpeg-20160410-win32.7z",
"https://ffmpeg.zeranoe.com/builds/win32/static/ffmpeg-20160508-git-caee88d-win32-static.7z" "https://ffmpeg.zeranoe.com/builds/win32/static/ffmpeg-20160409-git-0c90b2e-win32-static.7z"
}; };
} }
return new string[] { }; return new string[] { };

Loading…
Cancel
Save