Skip to content

Commit e53801f

Browse files
committed
Fix bug with multi-line page patterns. Version=2024-08-13a
1 parent c9944d1 commit e53801f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

hub.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
See pmwiki.php for full details and lack of warranty.
1111
*/
1212

13-
$RecipeInfo['ExtensionHub']['Version'] = '2024-08-13';
13+
$RecipeInfo['ExtensionHub']['Version'] = '2024-08-13a';
1414
SDVA($FmtPV, [
1515
'$ExtHubVersion' => '$GLOBALS["RecipeInfo"]["ExtensionHub"]["Version"]',
1616
'$ExtPubDirUrl' => 'extFarmPubDirUrl()',
@@ -516,7 +516,7 @@ function extGetIncluded($pagename = '') { # ''=initial
516516
elseif($pagename !== '' && $conf['xPriority']>100) {
517517
foreach($conf['=conf'] as $a) {
518518
if (!$a['xEnabled']) continue;
519-
$pat = $a['xNamePatterns'];
519+
$pat = preg_replace('/[,\\s]+/', ',', $a['xNamePatterns']);
520520
if($pat === '*' || $pat === '*.*' || MatchNames($pagename, $pat)) {
521521
$priority = $conf['xPriority']<=200
522522
? 1+$conf['xPriority']/100
@@ -736,7 +736,7 @@ function FmtExtList($pagename, $d, $args) {
736736
? $xHub['StatusIcons']['active']
737737
: $xHub['StatusIcons']['inactive'];
738738

739-
$np = preg_replace('!\\s+!', ' ', $a['xNamePatterns']);
739+
$np = preg_replace('/[,\\s]+/', ',', $a['xNamePatterns']);
740740
$select .= "(:input select i $i \"$icon $np\":)";
741741
$j = $i+1;
742742
}

0 commit comments

Comments
 (0)