summaryrefslogtreecommitdiffstats
path: root/core/Controller/SvgController.php
diff options
context:
space:
mode:
Diffstat (limited to 'core/Controller/SvgController.php')
-rw-r--r--core/Controller/SvgController.php5
1 files changed, 1 insertions, 4 deletions
diff --git a/core/Controller/SvgController.php b/core/Controller/SvgController.php
index 1fad9c39c3b..c6bf7b94da3 100644
--- a/core/Controller/SvgController.php
+++ b/core/Controller/SvgController.php
@@ -29,7 +29,6 @@ use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataDisplayResponse;
use OCP\AppFramework\Http\NotFoundResponse;
use OCP\AppFramework\Utility\ITimeFactory;
-use OCP\Files\NotFoundException;
use OCP\App\IAppManager;
use OCP\IRequest;
@@ -91,7 +90,7 @@ class SvgController extends Controller {
$appRootPath = $this->appManager->getAppPath($app);
$appPath = substr($appRootPath, strlen($this->serverRoot));
-
+
if (!$appPath) {
return new NotFoundResponse();
}
@@ -99,7 +98,6 @@ class SvgController extends Controller {
return $this->getSvg($path, $color, $fileName);
}
-
/**
* Generate svg from filename with the requested color
*
@@ -120,7 +118,6 @@ class SvgController extends Controller {
// add fill (fill is not present on black elements)
$fillRe = '/<((circle|rect|path)((?!fill)[a-z0-9 =".\-#():;])+)\/>/mi';
-
$svg = preg_replace($fillRe, '<$1 fill="#' . $color . '"/>', $svg);
// replace any fill or stroke colors