Always set cast receivers during migration (#11516)

This commit is contained in:
Cody Robibero 2024-05-10 07:34:08 -06:00 committed by GitHub
parent 44b03a3315
commit 5d2a1da73e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -32,24 +32,20 @@ public class AddDefaultCastReceivers : IMigrationRoutine
/// <inheritdoc /> /// <inheritdoc />
public void Perform() public void Perform()
{ {
// Only add if receiver list is empty. _serverConfigurationManager.Configuration.CastReceiverApplications =
if (_serverConfigurationManager.Configuration.CastReceiverApplications.Length == 0) [
{ new()
_serverConfigurationManager.Configuration.CastReceiverApplications = new CastReceiverApplication[]
{ {
new() Id = "F007D354",
{ Name = "Stable"
Id = "F007D354", },
Name = "Stable" new()
}, {
new() Id = "6F511C87",
{ Name = "Unstable"
Id = "6F511C87", }
Name = "Unstable" ];
}
};
_serverConfigurationManager.SaveConfiguration(); _serverConfigurationManager.SaveConfiguration();
}
} }
} }