jellyfin-server/MediaBrowser.Api/HttpHandlers/UsersHandler.cs
LukePulverenti Luke Pulverenti luke pulverenti cb7f04e4d3 Upgraded Protobuf, and added api support for it
2012-08-29 08:21:56 -04:00

18 lines
540 B
C#

using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using MediaBrowser.Common.Net.Handlers;
using MediaBrowser.Controller;
using MediaBrowser.Model.DTO;
namespace MediaBrowser.Api.HttpHandlers
{
class UsersHandler : BaseJsonHandler<IEnumerable<DTOUser>>
{
protected override Task<IEnumerable<DTOUser>> GetObjectToSerialize()
{
return Task.FromResult<IEnumerable<DTOUser>>(Kernel.Instance.Users.Select(u => ApiService.GetDTOUser(u)));
}
}
}