diff --git a/services/Parser/Nodes/NodeFooter.php b/services/Parser/Nodes/NodeFooter.php index f3332dd..7bcae2d 100644 --- a/services/Parser/Nodes/NodeFooter.php +++ b/services/Parser/Nodes/NodeFooter.php @@ -11,6 +11,6 @@ class NodeFooter extends Node { public function isEmpty( $data ) { $links = trim( $data['value'] ); - return empty( $links ); + return empty( $links ) && $links != '0'; } } diff --git a/tests/NodeFooterTest.php b/tests/NodeFooterTest.php index 24317d8..5366eb7 100644 --- a/tests/NodeFooterTest.php +++ b/tests/NodeFooterTest.php @@ -25,7 +25,11 @@ class NodeFooterTest extends WikiaBaseTest { ], [ 'string' => '', - 'expectedOutput' => true + 'expectedOutput' => false + ], + [ + 'string' => '', + 'expectedOutput' => false ], [ 'string' => '',