Skip to content

V15 does not list "other URLs" from IUrlProvider #17952

@kjac

Description

@kjac

Which Umbraco version are you using? (Please write the exact version, example: 10.1.0)

V15

Bug summary

The URLs returned by IUrlProvider.GetOtherUrls(int id, Uri current) are not listed in the V15 backoffice.

Specifics

Given the following URL provider:

using Umbraco.Cms.Core.Composing;
using Umbraco.Cms.Core.Models.PublishedContent;
using Umbraco.Cms.Core.Routing;

namespace Umbraco.Cms.Web.UI.Custom;

public class MyUrlProvider : IUrlProvider
{
    public UrlInfo? GetUrl(IPublishedContent content, UrlMode mode, string? culture, Uri current) => null;

    public IEnumerable<UrlInfo> GetOtherUrls(int id, Uri current) =>
    [
        new UrlInfo($"https://some.where/{id}", true, null)
    ];
}

public class MyUrlProviderComposer : IComposer
{
    public void Compose(IUmbracoBuilder builder)
        => builder.UrlProviders().Insert<MyUrlProvider>();
}

V13 lists the "other URLs":

image

...but V15 does not:

image

Indeed, the "other URLs" ($"https://some.where/{id}") aren't included in the endpoint response:

image

Steps to reproduce

Add the example URL provider to a V15 site and rebuild. The "other URLs" are missing from the "Info" section.

Expected result / actual result

No response

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions