aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-08-20 14:43:13 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-08-20 14:43:13 -0400
commitacd60f1d85f88e19b114ba0cc59af3fb98589064 (patch)
tree38a02ce0c79df16195957377082638df720165dc /MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs
parent234dcaf458b935a7941d5d8dc70496dd4df83ffc (diff)
update admin session filter
Diffstat (limited to 'MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs')
-rw-r--r--MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs17
1 files changed, 7 insertions, 10 deletions
diff --git a/MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs b/MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs
index 620eea774..414fda400 100644
--- a/MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs
+++ b/MediaBrowser.Server.Implementations/EntryPoints/RecordingNotifier.cs
@@ -54,18 +54,15 @@ namespace MediaBrowser.Server.Implementations.EntryPoints
private async void SendMessage(string name, TimerEventInfo info)
{
- var users = _userManager.Users.Where(i => i.Policy.EnableLiveTvAccess).ToList();
+ var users = _userManager.Users.Where(i => i.Policy.EnableLiveTvAccess).Select(i => i.Id.ToString("N")).ToList();
- foreach (var user in users)
+ try
{
- try
- {
- await _sessionManager.SendMessageToUserSessions<TimerEventInfo>(user.Id.ToString("N"), name, info, CancellationToken.None);
- }
- catch (Exception ex)
- {
- _logger.ErrorException("Error sending message", ex);
- }
+ await _sessionManager.SendMessageToUserSessions<TimerEventInfo>(users, name, info, CancellationToken.None);
+ }
+ catch (Exception ex)
+ {
+ _logger.ErrorException("Error sending message", ex);
}
}