aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Library/ExclusiveLiveStream.cs
diff options
context:
space:
mode:
authorBond-009 <bond.009@outlook.com>2020-07-24 09:40:44 +0200
committerGitHub <noreply@github.com>2020-07-24 09:40:44 +0200
commit3ff110984a0a003ab8323482e94557d26f3fec85 (patch)
tree8aa4f30696598c4c158bd9286a403d6017b7e612 /Emby.Server.Implementations/Library/ExclusiveLiveStream.cs
parenta23292f363c0bae2e9d4dbbf1359234feedd3799 (diff)
parentf5a3cc654fc8646e633489919b4a8b9e7d3c48fe (diff)
Merge branch 'master' into readonlyspan
Diffstat (limited to 'Emby.Server.Implementations/Library/ExclusiveLiveStream.cs')
-rw-r--r--Emby.Server.Implementations/Library/ExclusiveLiveStream.cs24
1 files changed, 12 insertions, 12 deletions
diff --git a/Emby.Server.Implementations/Library/ExclusiveLiveStream.cs b/Emby.Server.Implementations/Library/ExclusiveLiveStream.cs
index ab39a7223..236453e80 100644
--- a/Emby.Server.Implementations/Library/ExclusiveLiveStream.cs
+++ b/Emby.Server.Implementations/Library/ExclusiveLiveStream.cs
@@ -11,6 +11,17 @@ namespace Emby.Server.Implementations.Library
{
public class ExclusiveLiveStream : ILiveStream
{
+ private readonly Func<Task> _closeFn;
+
+ public ExclusiveLiveStream(MediaSourceInfo mediaSource, Func<Task> closeFn)
+ {
+ MediaSource = mediaSource;
+ EnableStreamSharing = false;
+ _closeFn = closeFn;
+ ConsumerCount = 1;
+ UniqueId = Guid.NewGuid().ToString("N", CultureInfo.InvariantCulture);
+ }
+
public int ConsumerCount { get; set; }
public string OriginalStreamId { get; set; }
@@ -21,18 +32,7 @@ namespace Emby.Server.Implementations.Library
public MediaSourceInfo MediaSource { get; set; }
- public string UniqueId { get; private set; }
-
- private Func<Task> _closeFn;
-
- public ExclusiveLiveStream(MediaSourceInfo mediaSource, Func<Task> closeFn)
- {
- MediaSource = mediaSource;
- EnableStreamSharing = false;
- _closeFn = closeFn;
- ConsumerCount = 1;
- UniqueId = Guid.NewGuid().ToString("N", CultureInfo.InvariantCulture);
- }
+ public string UniqueId { get; }
public Task Close()
{