From 6abeff9f0987170c24c34f9ad1933f37acdd2faf Mon Sep 17 00:00:00 2001 From: damianedwards Date: Mon, 18 May 2015 12:12:47 -0700 Subject: [PATCH] Add missing [NotNull] attributes on StringLocalizerExtensions --- .../StringLocalizerExtensions.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Microsoft.Framework.Localization.Abstractions/StringLocalizerExtensions.cs b/src/Microsoft.Framework.Localization.Abstractions/StringLocalizerExtensions.cs index 78ed2625a0..c3cd604ad6 100644 --- a/src/Microsoft.Framework.Localization.Abstractions/StringLocalizerExtensions.cs +++ b/src/Microsoft.Framework.Localization.Abstractions/StringLocalizerExtensions.cs @@ -1,6 +1,8 @@ // Copyright (c) .NET Foundation. All rights reserved. // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. +using Microsoft.Framework.Internal; + namespace Microsoft.Framework.Localization { public static class StringLocalizerExtensions @@ -10,7 +12,7 @@ namespace Microsoft.Framework.Localization /// /// The name of the string resource. /// The string resource as a . - public static LocalizedString GetString(this IStringLocalizer stringLocalizer, string name) + public static LocalizedString GetString([NotNull] this IStringLocalizer stringLocalizer, [NotNull] string name) { return stringLocalizer[name]; } @@ -21,7 +23,7 @@ namespace Microsoft.Framework.Localization /// The name of the string resource. /// The values to format the string with. /// The formatted string resource as a . - public static LocalizedString GetString(this IStringLocalizer stringLocalizer, string name, params object[] arguments) + public static LocalizedString GetString([NotNull] this IStringLocalizer stringLocalizer, [NotNull] string name, params object[] arguments) { return stringLocalizer[name, arguments]; }