Skip to content

CDN configuration from the site general settings is ignored #17

@kumards

Description

@kumards

There is a configuration "Use CDN" under site general settings is ignored when combinator is enabled. It always picks the local version and falls back to cdn only when local resource url is not set.
I see the below method from ResourceDefinitionExtensions.cs is used to get the full path which has no access to the site settings.

 public static string GetFullPath(this ResourceDefinition resource)
        {
            if (string.IsNullOrEmpty(resource.Url)) return resource.UrlCdn;

            if (resource.Url.Contains("~")) return resource.Url;

            return Path.Combine(resource.BasePath, resource.Url);
        }

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions