1
0
mirror of https://github.com/processwire/processwire.git synced 2025-08-08 07:47:00 +02:00

Update ProcessModule to improve the readme URL generation

This commit is contained in:
Ryan Cramer
2024-03-01 15:56:31 -05:00
parent 4099035708
commit 4b55979624

View File

@@ -2009,7 +2009,7 @@ class ProcessModule extends Process {
$readmeFile = $readmePath . $basename;
if(!file_exists($readmeFile)) continue;
$icon = wireIconMarkup('file-text-o');
$readmeUrl = str_replace('/edit', '/readme', $modules->getModuleEditUrl($moduleName));
$readmeUrl = str_replace(array('/edit/?', '/edit?'), '/readme/?', $modules->getModuleEditUrl($moduleName));
$supportFiles[$readmeType] = "<a class='pw-modal' href='$readmeUrl&amp;type=$readmeType'>$icon $basename</a>";
}