fix some sonar warnings

This commit is contained in:
troosan 2018-11-30 22:59:21 +01:00
parent 6a7594630c
commit a44aee8c34
2 changed files with 3 additions and 2 deletions

View File

@ -2185,6 +2185,8 @@ class MsDoc extends AbstractReader implements ReaderInterface
$sprmCPicLocation += $embeddedBlipRH['recLen']; $sprmCPicLocation += $embeddedBlipRH['recLen'];
break; break;
case self::OFFICEARTBLIPPNG:
break;
default: default:
// print_r(dechex($embeddedBlipRH['recType'])); // print_r(dechex($embeddedBlipRH['recType']));
} }

View File

@ -531,6 +531,7 @@ class Html
$styles['bgColor'] = trim($cValue, '#'); $styles['bgColor'] = trim($cValue, '#');
break; break;
case 'line-height': case 'line-height':
$matches = array();
if (preg_match('/([0-9]+\.?[0-9]*[a-z]+)/', $cValue, $matches)) { if (preg_match('/([0-9]+\.?[0-9]*[a-z]+)/', $cValue, $matches)) {
$spacingLineRule = \PhpOffice\PhpWord\SimpleType\LineSpacingRule::EXACT; $spacingLineRule = \PhpOffice\PhpWord\SimpleType\LineSpacingRule::EXACT;
$spacing = Converter::cssToTwip($matches[1]) / \PhpOffice\PhpWord\Style\Paragraph::LINE_HEIGHT; $spacing = Converter::cssToTwip($matches[1]) / \PhpOffice\PhpWord\Style\Paragraph::LINE_HEIGHT;
@ -743,8 +744,6 @@ class Html
default: default:
return Jc::START; return Jc::START;
} }
return null;
} }
/** /**