From 911086980b6abcb8b27795685a661e377eb8f110 Mon Sep 17 00:00:00 2001 From: Umherirrender Date: Fri, 10 May 2019 18:15:05 +0200 Subject: [PATCH] Improve error messages on deleteOldFancyCaptchas maintenance script StatusValue::getErrors returns an array of messages, not strings. It cannot be use on implode(). Use wikitext as it the most readable on the console Change-Id: I4b794597f9bf35d3bc34c7d2c7691ee53d43b017 --- maintenance/DeleteOldFancyCaptchas.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/maintenance/DeleteOldFancyCaptchas.php b/maintenance/DeleteOldFancyCaptchas.php index f8a6c1e62..9dc693d61 100644 --- a/maintenance/DeleteOldFancyCaptchas.php +++ b/maintenance/DeleteOldFancyCaptchas.php @@ -82,8 +82,9 @@ class DeleteOldFancyCaptchas extends Maintenance { if ( $ret->isOK() ) { $this->output( "$count old fancy captchas deleted.\n" ); } else { + $status = Status::wrap( $ret ); $this->output( "Deleting old captchas errored.\n" ); - $this->output( implode( "\n", $ret->getErrors() ) ); + $this->output( $status->getWikiText( false, false, 'en' ) ); } } }