diff options
author | Julius Härtl <jus@bitgrid.net> | 2018-07-26 22:08:48 +0200 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2018-07-26 22:08:48 +0200 |
commit | 8aa0f0485df5238739e9c3436f7aefebba53e66f (patch) | |
tree | b68b24e61271790b5b2be1a69546c200c0afde1e /lib | |
parent | 6514bf1e18485bd5e94ea01c5e49ca2d74c3023b (diff) | |
download | nextcloud-server-8aa0f0485df5238739e9c3436f7aefebba53e66f.tar.gz nextcloud-server-8aa0f0485df5238739e9c3436f7aefebba53e66f.zip |
Fix regex for icon urls
Use the version from the url rather than hardcoding v=1.
Also allow uppercase chars in the url, so that uppercase
hex color values will also be included
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Template/IconsCacher.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/Template/IconsCacher.php b/lib/private/Template/IconsCacher.php index e5ebecaf169..e5ea1b33815 100644 --- a/lib/private/Template/IconsCacher.php +++ b/lib/private/Template/IconsCacher.php @@ -47,7 +47,7 @@ class IconsCacher { protected $urlGenerator; /** @var string */ - private $iconVarRE = '/--(icon-[a-zA-Z0-9-]+): url\(["\']([a-z0-9-_\~\/\.]+)[^;]+;/m'; + private $iconVarRE = '/--(icon-[a-zA-Z0-9-]+): url\(["\']([a-zA-Z0-9-_\~\/\.\?\=]+)[^;]+;/m'; /** @var string */ private $fileName = 'icons-vars.css'; @@ -101,7 +101,7 @@ class IconsCacher { $data = ''; foreach ($icons as $icon => $url) { - $data .= "--$icon: url('$url?v=1');"; + $data .= "--$icon: url('$url');"; } if (strlen($data) > 0) { |