Fix AutocompleteResult.Value having no length limit (#3206)

This commit is contained in:
HEJOK254
2025-12-23 19:12:39 +00:00
committed by GitHub
parent 11a56bc96d
commit 161a91e73e

View File

@@ -46,6 +46,9 @@ namespace Discord
if (value is not string && !value.IsNumericType())
throw new ArgumentException($"{nameof(value)} must be a numeric type or a string! Value: \"{value}\"");
if (value is string stringValue)
Preconditions.AtMost(stringValue.Length, 100, nameof(Value));
_value = value;
}
}