From: Andrew Harris Date: Sun, 13 Dec 2015 19:02:38 +0000 (-0330) Subject: Change documentation of formatTimePeriod X-Git-Tag: 1.31.0-rc.0~5124^2 X-Git-Url: https://git.cyclocoop.org/%7B%24admin_url%7Dcompta/operations/modifier.php?a=commitdiff_plain;h=66844a817660d5f2b97fe1fdad8971c6d2a0cea2;p=lhc%2Fweb%2Fwiklou.git Change documentation of formatTimePeriod Currently, the function formatTimePeriod does not have a very descriptive documentation and has a TODO tag on it to change the documentation Change the documentation to be more descriptive and remove the TODO Change-Id: Idde711f1d3d6cbe0ecab0c3b49c68a4876d9e8b2 --- diff --git a/languages/Language.php b/languages/Language.php index 7354155e51..7ef2effb98 100644 --- a/languages/Language.php +++ b/languages/Language.php @@ -4461,14 +4461,15 @@ class Language { } /** - * @todo Document + * Formats a time given in seconds into a string representation of that time. + * * @param int|float $seconds - * @param array $format Optional - * If $format['avoid'] === 'avoidseconds': don't mention seconds if $seconds >= 1 hour. - * If $format['avoid'] === 'avoidminutes': don't mention seconds/minutes if $seconds > 48 hours. + * @param array $format An optional argument that formats the returned string in different ways: + * If $format['avoid'] === 'avoidseconds': don't show seconds if $seconds >= 1 hour, + * If $format['avoid'] === 'avoidminutes': don't show seconds/minutes if $seconds > 48 hours, * If $format['noabbrevs'] is true: use 'seconds' and friends instead of 'seconds-abbrev' * and friends. - * For backwards compatibility, $format may also be one of the strings 'avoidseconds' + * @note For backwards compatibility, $format may also be one of the strings 'avoidseconds' * or 'avoidminutes'. * @return string */