From 95fa32eaaad49539b74b191fafa5b83d3bcb0b93 Mon Sep 17 00:00:00 2001 From: Emad Rad Date: Sat, 9 Nov 2024 11:25:09 +0330 Subject: [PATCH 1/2] chore: owner changed --- catalog-info.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/catalog-info.yaml b/catalog-info.yaml index 1d231394..fe60bcab 100644 --- a/catalog-info.yaml +++ b/catalog-info.yaml @@ -14,6 +14,6 @@ metadata: title: "Stage Site" icon: "Web" spec: - owner: "group:openedx-unmaintained" + owner: codewithemad type: 'website' lifecycle: 'production' From 76f41439e9702c6459eea466e6e01b0a039d25e0 Mon Sep 17 00:00:00 2001 From: Diana Catalina Olarte Date: Thu, 15 Aug 2024 18:42:05 +1000 Subject: [PATCH 2/2] fix: apply getPath to PUBLIC_PATH to allow use with CDN --- src/data/constants/app.js | 7 ++++--- src/data/constants/app.test.js | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/data/constants/app.js b/src/data/constants/app.js index cd6236f7..d314bff2 100644 --- a/src/data/constants/app.js +++ b/src/data/constants/app.js @@ -1,4 +1,5 @@ -import { getConfig } from '@edx/frontend-platform'; +import { getConfig, getPath } from '@edx/frontend-platform'; -export const routePath = () => `${getConfig().PUBLIC_PATH}:courseId`; -export const locationId = () => decodeURIComponent(window.location.pathname).replace(getConfig().PUBLIC_PATH, ''); +const publicPath = getPath(getConfig().PUBLIC_PATH); +export const routePath = () => `${publicPath}:courseId`; +export const locationId = () => decodeURIComponent(window.location.pathname).replace(publicPath, ''); diff --git a/src/data/constants/app.test.js b/src/data/constants/app.test.js index 21908022..232dc623 100644 --- a/src/data/constants/app.test.js +++ b/src/data/constants/app.test.js @@ -6,6 +6,7 @@ jest.unmock('./app'); jest.mock('@edx/frontend-platform', () => { const PUBLIC_PATH = '/test-public-path/'; return { + ...jest.requireActual('@edx/frontend-platform'), getConfig: () => ({ PUBLIC_PATH }), PUBLIC_PATH, };