mirror of
https://github.com/tgstation/tgstation-server.git
synced 2026-08-27 07:04:57 +01:00
Nullify DreamDaemonSettings
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Tgstation.Server.Host.Models
|
||||
{
|
||||
/// <inheritdoc />
|
||||
@@ -21,6 +19,6 @@ namespace Tgstation.Server.Host.Models
|
||||
/// The parent <see cref="Models.Instance"/>.
|
||||
/// </summary>
|
||||
[Required]
|
||||
public Instance Instance { get; set; }
|
||||
public Instance? Instance { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -74,14 +74,14 @@ namespace Tgstation.Server.Host.Utils
|
||||
var ddPorts = await databaseContext
|
||||
.DreamDaemonSettings
|
||||
.AsQueryable()
|
||||
.Where(x => x.Instance.SwarmIdentifer == swarmConfiguration.Identifier)
|
||||
.Where(x => x.Instance!.SwarmIdentifer == swarmConfiguration.Identifier)
|
||||
.Select(x => x.Port)
|
||||
.ToListAsync(cancellationToken);
|
||||
|
||||
var dmPorts = await databaseContext
|
||||
.DreamMakerSettings
|
||||
.AsQueryable()
|
||||
.Where(x => x.Instance.SwarmIdentifer == swarmConfiguration.Identifier)
|
||||
.Where(x => x.Instance!.SwarmIdentifer == swarmConfiguration.Identifier)
|
||||
.Select(x => x.ApiValidationPort)
|
||||
.ToListAsync(cancellationToken);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user