Skip to content

Commit 46e61d4

Browse files
simivarProgi1984
andcommitted
Apply suggestions from code review
Co-authored-by: Progi1984 <[email protected]>
1 parent 4b7e7e4 commit 46e61d4

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

src/PhpWord/TemplateProcessor.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -797,7 +797,6 @@ public function deleteRow(string $search): void
797797

798798
// Check if there's a cell spanning multiple rows.
799799
if (preg_match('#<w:vMerge w:val="restart"/>#', $xmlRow)) {
800-
// $extraRowStart = $rowEnd;
801800
$extraRowStart = $rowStart;
802801
while (true) {
803802
$extraRowStart = $this->findRowStart($extraRowStart + 1);
@@ -1182,7 +1181,7 @@ protected function findTableStart(int $offset): int
11821181
*
11831182
* @return integer
11841183
*/
1185-
protected function findTableEnd($offset)
1184+
protected function findTableEnd(int $offset): int
11861185
{
11871186
return strpos($this->tempDocumentMainPart, '</w:tbl>', $offset) + 7;
11881187
}

tests/PhpWordTests/TemplateProcessorTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ public function testXslStyleSheetCanNotBeAppliedOnFailureOfLoadingXmlFromTemplat
188188
* @covers ::saveAs
189189
* @test
190190
*/
191-
public function testDeleteRow()
191+
public function testDeleteRow(): void
192192
{
193193
$templateProcessor = new TemplateProcessor(__DIR__ . '/_files/templates/delete-row.docx');
194194

0 commit comments

Comments
 (0)