r100197 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r100196‎ | r100197 | r100198 >
Date:00:53, 19 October 2011
Author:kaldari
Status:ok
Tags:
Comment:
more accurate documentation for addValue() method
Modified paths:
  • /trunk/phase3/includes/api/ApiResult.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/api/ApiResult.php
@@ -246,11 +246,12 @@
247247
248248 /**
249249 * Add value to the output data at the given path.
250 - * Path is an indexed array, each element specifying the branch at which to add the new value
251 - * Setting $path to array('a','b','c') is equivalent to data['a']['b']['c'] = $value
252 - * If $name is empty, the $value is added as a next list element data[] = $value
 250+ * Path can be an indexed array, each element specifying the branch at which to add the new
 251+ * value. Setting $path to array('a','b','c') is equivalent to data['a']['b']['c'] = $value.
 252+ * If $path is null, the value will be inserted at the data root.
 253+ * If $name is empty, the $value is added as a next list element data[] = $value.
253254 *
254 - * @param $path
 255+ * @param $path array|string|null
255256 * @param $name string
256257 * @param $value mixed
257258 * @param $overwrite bool

Status & tagging log