fix nullable annotation (#837)
This commit is contained in:
parent
66272cbe46
commit
4de18b516f
|
@ -50,7 +50,7 @@ namespace StardewModdingAPI.Framework.ModHelpers
|
|||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public Translation Get(string key, object tokens)
|
||||
public Translation Get(string key, object? tokens)
|
||||
{
|
||||
return this.Translator.Get(key, tokens);
|
||||
}
|
||||
|
|
|
@ -72,7 +72,7 @@ namespace StardewModdingAPI.Framework
|
|||
/// <summary>Get a translation for the current locale.</summary>
|
||||
/// <param name="key">The translation key.</param>
|
||||
/// <param name="tokens">An object containing token key/value pairs. This can be an anonymous object (like <c>new { value = 42, name = "Cranberries" }</c>), a dictionary, or a class instance.</param>
|
||||
public Translation Get(string key, object tokens)
|
||||
public Translation Get(string key, object? tokens)
|
||||
{
|
||||
return this.Get(key).Tokens(tokens);
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@ namespace StardewModdingAPI
|
|||
/// <summary>Get a translation for the current locale.</summary>
|
||||
/// <param name="key">The translation key.</param>
|
||||
/// <param name="tokens">An object containing token key/value pairs. This can be an anonymous object (like <c>new { value = 42, name = "Cranberries" }</c>), a dictionary, or a class instance.</param>
|
||||
Translation Get(string key, object tokens);
|
||||
Translation Get(string key, object? tokens);
|
||||
|
||||
/// <summary>Get a translation in every locale for which it's defined.</summary>
|
||||
/// <param name="key">The translation key.</param>
|
||||
|
|
Loading…
Reference in New Issue