mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools
synced 2024-11-24 08:23:52 +00:00
CommentItem: Fix warning when the comment is empty
Bug: T302927 Change-Id: I5e92a71327e9563adb2427da62647a21244b803c
This commit is contained in:
parent
6e75e580a9
commit
0c59779126
|
@ -75,8 +75,8 @@ class CommentItem extends ThreadItem {
|
||||||
// Find a trailing text node
|
// Find a trailing text node
|
||||||
$lastChild = $fragment->lastChild;
|
$lastChild = $fragment->lastChild;
|
||||||
while (
|
while (
|
||||||
!( $lastChild instanceof Text ) &&
|
$lastChild &&
|
||||||
$lastChild->lastChild
|
!( $lastChild instanceof Text )
|
||||||
) {
|
) {
|
||||||
$lastChild = $lastChild->lastChild;
|
$lastChild = $lastChild->lastChild;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue