Skip to content

Commit 8c3e677

Browse files
committed
use pass $this->dom->documentElement only on search
1 parent 7f84298 commit 8c3e677

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

system/Test/DOMParser.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public function __construct()
7676
*/
7777
public function getBody(): string
7878
{
79-
return $this->dom->saveHTML($this->dom->documentElement);
79+
return $this->dom->saveHTML();
8080
}
8181

8282
/**
@@ -143,7 +143,7 @@ public function see(string $search = null, string $element = null): bool
143143
if (is_null($element))
144144
{
145145
$content = $this->dom->saveHTML($this->dom->documentElement);
146-
return strpos($content, $search) !== false;
146+
return mb_strpos($content, $search) !== false;
147147
}
148148

149149
$result = $this->doXPath($search, $element);

0 commit comments

Comments
 (0)