Browse Source

Fix colorizeSvg with transformations that contain a comma (,)

Signed-off-by: Joas Schilling <coding@schilljs.com>
Joas Schilling 5 years ago
parent
commit
f39dacf1fb
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lib/private/Template/IconsCacher.php

+ 1 - 1
lib/private/Template/IconsCacher.php

@@ -180,7 +180,7 @@ class IconsCacher {
 	 */
 	public function colorizeSvg($svg, $color): string {
 		// add fill (fill is not present on black elements)
-		$fillRe = '/<((circle|rect|path)((?!fill)[a-z0-9 =".\-#():;])+)\/>/mi';
+		$fillRe = '/<((circle|rect|path)((?!fill)[a-z0-9 =".\-#():;,])+)\/>/mi';
 		$svg = preg_replace($fillRe, '<$1 fill="#' . $color . '"/>', $svg);
 
 		// replace any fill or stroke colors