Clean up extension methods (#17051)
Co-authored-by: Andy Butland <abutland73@gmail.com>
This commit is contained in:
@@ -675,28 +675,6 @@ public static class FriendlyPublishedContentExtensions
|
||||
public static string Url(this IPublishedContent content, string? culture = null, UrlMode mode = UrlMode.Default)
|
||||
=> content.Url(PublishedUrlProvider, culture, mode);
|
||||
|
||||
/// <summary>
|
||||
/// Gets the children of the content in a DataTable.
|
||||
/// </summary>
|
||||
/// <param name="content">The content.</param>
|
||||
/// <param name="contentTypeAliasFilter">An optional content type alias.</param>
|
||||
/// <param name="culture">
|
||||
/// The specific culture to filter for. If null is used the current culture is used. (Default is
|
||||
/// null)
|
||||
/// </param>
|
||||
/// <returns>The children of the content.</returns>
|
||||
[Obsolete("This method is no longer used in Umbraco. The method will be removed in Umbraco 17.")]
|
||||
public static DataTable ChildrenAsTable(this IPublishedContent content, string contentTypeAliasFilter = "", string? culture = null)
|
||||
=> content.ChildrenAsTable(
|
||||
GetNavigationQueryService(content),
|
||||
GetPublishedStatusFilteringService(content),
|
||||
ContentTypeService,
|
||||
MediaTypeService,
|
||||
MemberTypeService,
|
||||
PublishedUrlProvider,
|
||||
contentTypeAliasFilter,
|
||||
culture);
|
||||
|
||||
/// <summary>
|
||||
/// Gets the url for a media.
|
||||
/// </summary>
|
||||
|
||||
@@ -3,6 +3,7 @@ using System.Diagnostics.CodeAnalysis;
|
||||
using System.Net;
|
||||
using System.Web;
|
||||
using Microsoft.AspNetCore.DataProtection;
|
||||
using Microsoft.AspNetCore.Routing;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Umbraco.Cms.Core;
|
||||
using Umbraco.Cms.Web.Common.Constants;
|
||||
@@ -65,14 +66,7 @@ public class EncryptionHelper
|
||||
string? additionalRouteValsAsQuery;
|
||||
if (additionalRouteVals != null)
|
||||
{
|
||||
if (additionalRouteVals is Dictionary<string, object> additionalRouteValsAsDictionary)
|
||||
{
|
||||
additionalRouteValsAsQuery = additionalRouteValsAsDictionary.ToQueryString();
|
||||
}
|
||||
else
|
||||
{
|
||||
additionalRouteValsAsQuery = additionalRouteVals.ToDictionary<object>().ToQueryString();
|
||||
}
|
||||
additionalRouteValsAsQuery = new RouteValueDictionary(additionalRouteVals).ToQueryString();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user