Removes the redundant null guards from the metadata value objects

This commit is contained in:
BinaryAlley committed 2026-09-26 17:54:22 +03:00
1 parent ef913f5c9e
commit 7534155f0e
4 files changed
+2 -42

No files matched your search

@@ -1,7 +1,6 @@
#region ========================================================================= USING =====================================================================================
using Lumina.Domain.Common.Models.Core;
using Lumina.Domain.Common.Primitives;
using System;
using System.Collections.Generic;
using System.Diagnostics;
#endregion
@@ -68,7 +67,6 @@ public abstract class BaseMetadata : ValueObject
/// <param name="tags">The list of tags of the element to which this metadata object belongs to.</param>
/// <param name="language">The optional language of the element to which this metadata object belongs to, if applicable.</param>
/// <param name="originalLanguage">The optional original language of the element to which this metadata object belongs to, if applicable.</param>
/// <exception cref="ArgumentNullException">Thrown when the <see cref="title"/> value is <see langword="null"/></exception>
protected BaseMetadata(
string title,
Optional<string> originalTitle,
@@ -79,7 +77,7 @@ public abstract class BaseMetadata : ValueObject
Optional<LanguageInfo> language,
Optional<LanguageInfo> originalLanguage)
{
Title = title ?? throw new ArgumentNullException(nameof(title));
Title = title;
OriginalTitle = originalTitle;
Description = description;
ReleaseInfo = releaseInfo;