import from review #2168110

This commit is contained in:
Remi Collet 2023-06-19 18:07:57 +02:00
commit 7b6eb4e4bf
5 changed files with 893 additions and 0 deletions

View file

@ -0,0 +1,16 @@
diff -up src/Report/Html/Facade.php.rpm src/Report/Html/Facade.php
--- src/Report/Html/Facade.php.rpm 2017-11-28 06:14:43.754075896 +0100
+++ src/Report/Html/Facade.php 2017-11-28 06:16:31.423668936 +0100
@@ -144,7 +144,11 @@ class Facade
$dir = $this->getDirectory($target . '.fonts');
\copy($this->templatePath . 'fonts/glyphicons-halflings-regular.eot', $dir . 'glyphicons-halflings-regular.eot');
\copy($this->templatePath . 'fonts/glyphicons-halflings-regular.svg', $dir . 'glyphicons-halflings-regular.svg');
- \copy($this->templatePath . 'fonts/glyphicons-halflings-regular.ttf', $dir . 'glyphicons-halflings-regular.ttf');
+ if (file_exists($font='/usr/share/fonts/glyphicons-halflings/glyphicons-halflings-regular.ttf')) { // System font
+ \copy($font, $dir . 'glyphicons-halflings-regular.ttf');
+ } else {
+ \copy($this->templatePath . 'fonts/glyphicons-halflings-regular.ttf', $dir . 'glyphicons-halflings-regular.ttf');
+ }
\copy($this->templatePath . 'fonts/glyphicons-halflings-regular.woff', $dir . 'glyphicons-halflings-regular.woff');
\copy($this->templatePath . 'fonts/glyphicons-halflings-regular.woff2', $dir . 'glyphicons-halflings-regular.woff2');