From b4c180018eb893b9838e9be37fbb598b1e22a65a Mon Sep 17 00:00:00 2001 From: oleibman <10341515+oleibman@users.noreply.github.com> Date: Mon, 18 Sep 2023 16:46:03 -0700 Subject: [PATCH] Minor Signature Incompatibilities --- src/PhpWord/Writer/ODText.php | 4 +--- src/PhpWord/Writer/RTF.php | 4 +--- src/PhpWord/Writer/Word2007.php | 4 +--- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/src/PhpWord/Writer/ODText.php b/src/PhpWord/Writer/ODText.php index 6d54706c8e..3eaf80ad4f 100644 --- a/src/PhpWord/Writer/ODText.php +++ b/src/PhpWord/Writer/ODText.php @@ -70,10 +70,8 @@ public function __construct(?PhpWord $phpWord = null) /** * Save PhpWord to file. - * - * @param string $filename */ - public function save($filename = null): void + public function save(string $filename): void { $filename = $this->getTempFile($filename); $zip = $this->getZipArchive($filename); diff --git a/src/PhpWord/Writer/RTF.php b/src/PhpWord/Writer/RTF.php index ebbf8f56c0..1d89c03643 100644 --- a/src/PhpWord/Writer/RTF.php +++ b/src/PhpWord/Writer/RTF.php @@ -56,10 +56,8 @@ public function __construct(?PhpWord $phpWord = null) /** * Save content to file. - * - * @param string $filename */ - public function save($filename = null): void + public function save(string $filename): void { $this->writeFile($this->openFile($filename), $this->getContent()); } diff --git a/src/PhpWord/Writer/Word2007.php b/src/PhpWord/Writer/Word2007.php index ae10ba5a74..ab4fd1e3eb 100644 --- a/src/PhpWord/Writer/Word2007.php +++ b/src/PhpWord/Writer/Word2007.php @@ -91,10 +91,8 @@ public function __construct(?PhpWord $phpWord = null) /** * Save document by name. - * - * @param string $filename */ - public function save($filename = null): void + public function save(string $filename): void { $filename = $this->getTempFile($filename); $zip = $this->getZipArchive($filename);