Uploaded image for project: 'Hippo CMS'
  1. Hippo CMS
  2. CMS-13296

Regression: CDN host used in preview Page Model API

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • High
    • Resolution: Fixed
    • 14.1.0
    • 14.1.1, 14.2.0
    • None
    • 1
    • Flagged
    • Quasar
    • Puma Sprint 233

    Description

      In the preview mode (Channel Manager), links to images were using the CDN host that is specified, which caused the images to not load.

      The problem seems to be in HstLinkImpl.toUrlForm(..) method. In that method there is an if-else statement:

      if (requestContext.isChannelManagerPreviewRequest() && !requestContext.isPageModelApiRequest()) {
          // some code
      }
      else {
          // code to prefix url with CdnHost if not blank
          ...
          // more code
      }
      

      In case of a client's SPA++ implementation, the React application requests the preview version of the 'resourceapi', so it is both a ChannelManagerPreviewRequest and a PageModelApiRequest, so it ends up in the 'else' part of the statement.

      This used to work in 13.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              jhoffman Jeroen Hoffman
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: