Closed YOUR1 closed 1 year ago
Checks are not related to my PR.
Error: composer/installers contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe.
I've updated composer.json, so after merging master this should be okay.
But I'm not quite sure. Why is $parserOptions->getIsPreview()
not working here? It feels like this fix of using the other hook to set the preview state is relying on the order of the hook execution, which is something we're meant to avoid I think.
The
$isPreview
variable would always be false; event though I was previewing the edit I made.Thus; a relative but simple fix is by using the EditPageGetPreviewContent hook and setting the newly added variable
$isPreviewing
to true whenever the edit is being previewed.