diff --git a/src/CommandLine/BaseAttribute.cs b/src/CommandLine/BaseAttribute.cs
index be0a3826..30e25f14 100644
--- a/src/CommandLine/BaseAttribute.cs
+++ b/src/CommandLine/BaseAttribute.cs
@@ -13,7 +13,7 @@ public abstract class BaseAttribute : Attribute
private int max;
private object @default;
private Infrastructure.LocalizableAttributeProperty helpText;
- private string metaValue;
+ private Infrastructure.LocalizableAttributeProperty metaValue;
private Type resourceType;
///
@@ -24,7 +24,7 @@ protected internal BaseAttribute()
min = -1;
max = -1;
helpText = new Infrastructure.LocalizableAttributeProperty(nameof(HelpText));
- metaValue = string.Empty;
+ metaValue = new Infrastructure.LocalizableAttributeProperty(nameof(MetaValue));
resourceType = null;
}
@@ -101,16 +101,8 @@ public string HelpText
///
public string MetaValue
{
- get { return metaValue; }
- set
- {
- if (value == null)
- {
- throw new ArgumentNullException("value");
- }
-
- metaValue = value;
- }
+ get => metaValue.Value ?? string.Empty;
+ set => metaValue.Value = value ?? throw new ArgumentNullException("value");
}
///