Merge branch 'hishamco-dev' into dev
This commit is contained in:
commit
8deb0b1137
|
|
@ -26,8 +26,6 @@ namespace Microsoft.AspNet.Localization
|
||||||
|
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
public override Task<RequestCulture> DetermineRequestCulture([NotNull] HttpContext httpContext)
|
public override Task<RequestCulture> DetermineRequestCulture([NotNull] HttpContext httpContext)
|
||||||
{
|
=> _provider(httpContext);
|
||||||
return _provider(httpContext);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -34,8 +34,6 @@ namespace Microsoft.AspNet.Builder
|
||||||
public static IApplicationBuilder UseRequestLocalization(
|
public static IApplicationBuilder UseRequestLocalization(
|
||||||
[NotNull] this IApplicationBuilder builder,
|
[NotNull] this IApplicationBuilder builder,
|
||||||
[NotNull] RequestLocalizationOptions options)
|
[NotNull] RequestLocalizationOptions options)
|
||||||
{
|
=> builder.UseMiddleware<RequestLocalizationMiddleware>(options);
|
||||||
return builder.UseMiddleware<RequestLocalizationMiddleware>(options);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -124,15 +124,9 @@ namespace Microsoft.Framework.Localization
|
||||||
/// Returns an <see cref="IEnumerator{LocalizedString}"/> for all strings in the current culture.
|
/// Returns an <see cref="IEnumerator{LocalizedString}"/> for all strings in the current culture.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns>The <see cref="IEnumerator{LocalizedString}"/>.</returns>
|
/// <returns>The <see cref="IEnumerator{LocalizedString}"/>.</returns>
|
||||||
public virtual IEnumerator<LocalizedString> GetEnumerator()
|
public virtual IEnumerator<LocalizedString> GetEnumerator() => GetEnumerator(CultureInfo.CurrentUICulture);
|
||||||
{
|
|
||||||
return GetEnumerator(CultureInfo.CurrentUICulture);
|
|
||||||
}
|
|
||||||
|
|
||||||
IEnumerator IEnumerable.GetEnumerator()
|
IEnumerator IEnumerable.GetEnumerator() => GetEnumerator();
|
||||||
{
|
|
||||||
return GetEnumerator();
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Returns an <see cref="IEnumerator{LocalizedString}"/> for all strings in the specified culture.
|
/// Returns an <see cref="IEnumerator{LocalizedString}"/> for all strings in the specified culture.
|
||||||
|
|
|
||||||
|
|
@ -70,9 +70,6 @@ namespace Microsoft.Framework.Localization
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
public override IEnumerator<LocalizedString> GetEnumerator()
|
public override IEnumerator<LocalizedString> GetEnumerator() => GetEnumerator(_culture);
|
||||||
{
|
|
||||||
return GetEnumerator(_culture);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue