aboutsummaryrefslogtreecommitdiffstats
path: root/includes/Status
diff options
context:
space:
mode:
authorBartosz Dziewoński <dziewonski@fastmail.fm>2024-04-03 01:32:58 +0200
committerBartosz Dziewoński <dziewonski@fastmail.fm>2024-04-10 00:13:04 +0200
commitf818da9351bcb73ac0169803df7019ed3e982890 (patch)
treecaecac6c9dbdac8db2338bdfeda76703bfac9127 /includes/Status
parent02044a5ba1a4355d9cd7c8b5f8f3f884728f1194 (diff)
downloadmediawikicore-f818da9351bcb73ac0169803df7019ed3e982890.tar.gz
mediawikicore-f818da9351bcb73ac0169803df7019ed3e982890.zip
StatusValue: Add a getter for MessageSpecifier list
An array of MessageSpecifier objects is easier to deal with than the "legacy error array" format, which is an array of whatever wfMessage() accepts, which can be a bunch of different things. Deprecate some existing getters. Change-Id: Ibc4ce11594cf36ce7b2495d2636ee080d3443b04
Diffstat (limited to 'includes/Status')
-rw-r--r--includes/Status/Status.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/includes/Status/Status.php b/includes/Status/Status.php
index 7634d274bc8f..fcdc7ca791fb 100644
--- a/includes/Status/Status.php
+++ b/includes/Status/Status.php
@@ -284,6 +284,7 @@ class Status extends StatusValue {
/**
* Get the list of errors (but not warnings)
*
+ * @deprecated since 1.43 Use `->getMessages( 'error' )` instead
* @return array[] A list in which each entry is an array with a message key as its first element.
* The remaining array elements are the message parameters.
* @phan-return non-empty-array[]
@@ -295,6 +296,7 @@ class Status extends StatusValue {
/**
* Get the list of warnings (but not errors)
*
+ * @deprecated since 1.43 Use `->getMessages( 'warning' )` instead
* @return array[] A list in which each entry is an array with a message key as its first element.
* The remaining array elements are the message parameters.
* @phan-return non-empty-array[]