Open
Description
Which Umbraco version are you using?
15.4.0
Bug summary
In previous versions (before v14) we were using DefaultUrlProvider as base for customizing URL's but as we started upgrading we saw that it's now the NewDefaultUrlProvider that is in the UrlProviderCollection. So far so good.
One weird thing is that it has two constructors: one marked as obsolete and one not. Bot using ILocalizationService which is marked as obsolete and set for removal in v15.
And since I'm currently on v15.4.0 I'm basically just wondering what is going on? 😆
Specifics
No response
Steps to reproduce
public NewCustomUrlProvider(IOptionsMonitor<RequestHandlerSettings> requestSettings,
ILogger<DefaultUrlProvider> logger,
ISiteDomainMapper siteDomainMapper,
IUmbracoContextAccessor umbracoContextAccessor,
UriUtility uriUtility,
ILocalizationService localizationService, //[Obsolete("Please use ILanguageService and IDictionaryItemService for localization. Will be removed in V15.")]
IPublishedContentCache publishedContentCache,
IDomainCache domainCache,
IIdKeyMap idKeyMap,
IDocumentUrlService documentUrlService,
IDocumentNavigationQueryService documentNavigationQueryService,
IPublishedContentStatusFilteringService publishedContentStatusFilteringService) : base(requestSettings, logger, siteDomainMapper, umbracoContextAccessor, uriUtility, localizationService, publishedContentCache, domainCache, idKeyMap, documentUrlService, documentNavigationQueryService, publishedContentStatusFilteringService)
{
}
Expected result / actual result
I would expect a constructor that accepts ILanguageService instead as its only purpose in NewDefaultUrlProvider is this:
var defaultCulture = _localizationService.GetDefaultLanguageIsoCode();