diff --git a/src/PhpWord/IOFactory.php b/src/PhpWord/IOFactory.php index 4f84cbb33b..c232ce8fb4 100644 --- a/src/PhpWord/IOFactory.php +++ b/src/PhpWord/IOFactory.php @@ -31,10 +31,8 @@ abstract class IOFactory * * @param string $name * @param array $config - * - * @return WriterInterface */ - public static function createWriter(PhpWord $phpWord, $name = 'Word2007', $config = []) : WriterInterface + public static function createWriter(PhpWord $phpWord, $name = 'Word2007', $config = []): WriterInterface { if ($name !== 'WriterInterface' && !in_array($name, ['ODText', 'RTF', 'Word2007', 'HTML', 'PDF'], true)) { throw new Exception("\"{$name}\" is not a valid writer."); diff --git a/src/PhpWord/Writer/AbstractWriter.php b/src/PhpWord/Writer/AbstractWriter.php index 0aee619707..d5f30b4a17 100644 --- a/src/PhpWord/Writer/AbstractWriter.php +++ b/src/PhpWord/Writer/AbstractWriter.php @@ -103,7 +103,6 @@ abstract class AbstractWriter implements WriterInterface /** * construct method. * - * @param PhpWord|null $phpWord * @param array $config */ public function __construct(?PhpWord $phpWord = null, $config = []) diff --git a/src/PhpWord/Writer/PDF/AbstractRenderer.php b/src/PhpWord/Writer/PDF/AbstractRenderer.php index b07aebb142..534372cd37 100644 --- a/src/PhpWord/Writer/PDF/AbstractRenderer.php +++ b/src/PhpWord/Writer/PDF/AbstractRenderer.php @@ -76,7 +76,6 @@ abstract class AbstractRenderer extends HTML /** * Create new instance. * - * @param PhpWord $phpWord * @param array $config */ public function __construct(PhpWord $phpWord, $config = []) diff --git a/src/PhpWord/Writer/Word2007.php b/src/PhpWord/Writer/Word2007.php index 32c58d0d30..9e1d308871 100644 --- a/src/PhpWord/Writer/Word2007.php +++ b/src/PhpWord/Writer/Word2007.php @@ -79,7 +79,7 @@ public function __construct(?PhpWord $phpWord = null, $config = []) foreach (array_keys($this->parts) as $partName) { $partClass = static::class . '\\Part\\' . $partName; if (class_exists($partClass)) { - /** @var \PhpOffice\PhpWord\Writer\Word2007\Part\AbstractPart $part Type hint */ + /** @var \PhpOffice\PhpWord\Writer\Word2007\Part\AbstractPart $part */ $part = new $partClass(); $part->setParentWriter($this); $this->writerParts[strtolower($partName)] = $part;