Index: trunk/extensions/Validator/RELEASE-NOTES |
— | — | @@ -7,8 +7,10 @@ |
8 | 8 | == Validator change log == |
9 | 9 | |
10 | 10 | === Validator 0.4.2 === |
11 | | -(2010-1x-xx) |
| 11 | +(2010-10-28) |
12 | 12 | |
| 13 | +* Fixed compatibility with MediaWiki 1.15.x. |
| 14 | + |
13 | 15 | * Removed the lowerCaseValue field in the Parameter class and replaced it's functionality with a ParameterManipulation. |
14 | 16 | |
15 | 17 | === Validator 0.4.1 === |
Index: trunk/extensions/Validator/Validator.php |
— | — | @@ -24,7 +24,7 @@ |
25 | 25 | die( 'Not an entry point.' ); |
26 | 26 | } |
27 | 27 | |
28 | | -define( 'Validator_VERSION', '0.4.2 alpha' ); |
| 28 | +define( 'Validator_VERSION', '0.4.2 rc1' ); |
29 | 29 | |
30 | 30 | // Register the internationalization file. |
31 | 31 | $wgExtensionMessagesFiles['Validator'] = dirname( __FILE__ ) . '/Validator.i18n.php'; |
— | — | @@ -38,12 +38,6 @@ |
39 | 39 | 'descriptionmsg' => 'validator-desc', |
40 | 40 | ); |
41 | 41 | |
42 | | -// This function has been deprecated in 1.16, but needed for earlier versions. |
43 | | -// It's present in 1.16 as a stub, but lets check if it exists in case it gets removed at some point. |
44 | | -if ( function_exists( 'wfLoadExtensionMessages' ) ) { |
45 | | - wfLoadExtensionMessages( 'Validator' ); |
46 | | -} |
47 | | - |
48 | 42 | // Autoload the classes. |
49 | 43 | $incDir = dirname( __FILE__ ) . '/includes/'; |
50 | 44 | $wgAutoloadClasses['CriterionValidationResult'] = $incDir . 'CriterionValidationResult.php'; |
— | — | @@ -83,5 +77,22 @@ |
84 | 78 | $wgAutoloadClasses['ValidatorListErrors'] = $incDir . 'parserHooks/Validator_ListErrors.php'; |
85 | 79 | unset( $incDir ); |
86 | 80 | |
| 81 | +$wgExtensionFunctions[] = 'efValidatorSetup'; |
| 82 | + |
| 83 | +/** |
| 84 | + * Function for backwards compatibility with MW 1.15.x. |
| 85 | + * |
| 86 | + * @since 0.4.2 |
| 87 | + */ |
| 88 | +function efValidatorSetup() { |
| 89 | + // This function has been deprecated in 1.16, but needed for earlier versions. |
| 90 | + // It's present in 1.16 as a stub, but lets check if it exists in case it gets removed at some point. |
| 91 | + if ( function_exists( 'wfLoadExtensionMessages' ) ) { |
| 92 | + wfLoadExtensionMessages( 'Validator' ); |
| 93 | + } |
| 94 | + |
| 95 | + return true; |
| 96 | +} |
| 97 | + |
87 | 98 | // Include the settings file. |
88 | 99 | require_once 'Validator_Settings.php'; |
\ No newline at end of file |