Merge "REST: Use ob_clean to wipe display_errors output"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Wed, 21 Aug 2019 16:18:50 +0000 (16:18 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Wed, 21 Aug 2019 16:18:50 +0000 (16:18 +0000)
includes/Rest/EntryPoint.php

index a14c1a1..ae01ae4 100644 (file)
@@ -90,6 +90,9 @@ class EntryPoint {
                                $cookie['options'] );
                }
 
+               // Clear all errors that might have been displayed if display_errors=On
+               ob_clean();
+
                $stream = $response->getBody();
                $stream->rewind();
                if ( $stream instanceof CopyableStreamInterface ) {