Index: trunk/phase3/includes/DefaultSettings.php |
— | — | @@ -4084,16 +4084,11 @@ |
4085 | 4085 | $wgDevelopmentWarnings = false; |
4086 | 4086 | |
4087 | 4087 | /** |
4088 | | - * $wgDeprecationWarnings['limit'] |
4089 | 4088 | * Release limitation to wfDeprecated warnings, if set to a release number |
4090 | 4089 | * development warnings will not be generated for deprecations added in releases |
4091 | 4090 | * after the limit. |
4092 | | - * |
4093 | | - * $wgDeprecationWarnings['whitelist'] |
4094 | | - * Function name whitelist for wfDeprecated warnings. You will not be warned |
4095 | | - * for usage of deprecated functions in this list. |
4096 | 4091 | */ |
4097 | | -$wgDeprecationWarnings = array( 'limit' => '1.17', 'whitelist' => array() ); |
| 4092 | +$wgDeprecationReleaseLimit = '1.17'; |
4098 | 4093 | |
4099 | 4094 | /** Only record profiling info for pages that took longer than this */ |
4100 | 4095 | $wgProfileLimit = 0.0; |
Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -3460,13 +3460,14 @@ |
3461 | 3461 | */ |
3462 | 3462 | function wfDeprecated( $function, $version = false, $component = false ) { |
3463 | 3463 | static $functionsWarned = array(); |
3464 | | - global $wgDeprecationWarnings; |
3465 | 3464 | |
3466 | | - if ( !in_array( $function, $wgDeprecationWarnings['whitelist'] ) && !isset( $functionsWarned[$function] ) ) { |
| 3465 | + if ( !isset( $functionsWarned[$function] ) ) { |
3467 | 3466 | $functionsWarned[$function] = true; |
3468 | 3467 | |
3469 | 3468 | if ( $version ) { |
3470 | | - if ( $wgDeprecationWarnings['limit'] && $component === false ) { |
| 3469 | + global $wgDeprecationReleaseLimit; |
| 3470 | + |
| 3471 | + if ( $wgDeprecationReleaseLimit && $component === false ) { |
3471 | 3472 | # Strip -* off the end of $version so that branches can use the |
3472 | 3473 | # format #.##-branchname to avoid issues if the branch is merged into |
3473 | 3474 | # a version of MediaWiki later than what it was branched from |
— | — | @@ -3474,7 +3475,7 @@ |
3475 | 3476 | |
3476 | 3477 | # If the comparableVersion is larger than our release limit then |
3477 | 3478 | # skip the warning message for the deprecation |
3478 | | - if ( version_compare( $wgDeprecationWarnings['limit'], $comparableVersion, '<' ) ) { |
| 3479 | + if ( version_compare( $wgDeprecationReleaseLimit, $comparableVersion, '<' ) ) { |
3479 | 3480 | return; |
3480 | 3481 | } |
3481 | 3482 | } |