Skip to content

Commit

Permalink
temp: temporarily disable editor static URL substitution (it breaks l…
Browse files Browse the repository at this point in the history
…ibrary assets)
  • Loading branch information
ormsbee committed Sep 30, 2024
1 parent 5de3f10 commit 1cd21e6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/editors/sharedComponents/TinyMceWidget/hooks.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ export const replaceStaticWithAsset = ({
const isCorrectAssetFormat = assetSrc.startsWith('/asset') && assetSrc.match(/\/asset-v1:\S+[+]\S+[@]\S+[+]\S+[@]/g)?.length >= 1;

Check failure on line 100 in src/editors/sharedComponents/TinyMceWidget/hooks.js

View workflow job for this annotation

GitHub Actions / tests (20)

'isCorrectAssetFormat' is assigned a value but never used
// assets in expandable text areas so not support relative urls so all assets must have the lms
// endpoint prepended to the relative url
/*
if (editorType === 'expandable') {
if (isCorrectAssetFormat) {
staticFullUrl = `${lmsEndpointUrl}${assetSrc}`;
Expand All @@ -114,6 +115,7 @@ export const replaceStaticWithAsset = ({
content = currentContent.replace(currentSrc, staticFullUrl);
hasChanges = true;
}
*/
});
if (hasChanges) { return content; }
}
Expand Down

0 comments on commit 1cd21e6

Please sign in to comment.