Index: trunk/extensions/ArticleFeedbackv5/ArticleFeedbackv5.hooks.php |
— | — | @@ -267,11 +267,14 @@ |
268 | 268 | * @param $preferences |
269 | 269 | */ |
270 | 270 | public static function getPreferences( $user, &$preferences ) { |
271 | | - $preferences['articlefeedbackv5-disable'] = array( |
272 | | - 'type' => 'check', |
273 | | - 'section' => 'rendering/advancedrendering', |
274 | | - 'label-message' => 'articlefeedbackv5-disable-preference', |
275 | | - ); |
| 271 | + // need to check for existing key, if deployed simultaneously with AFTv4 |
| 272 | + if( !array_key_exists( 'articlefeedbackv5-disable', $preferences ) ) { |
| 273 | + $preferences['articlefeedbackv5-disable'] = array( |
| 274 | + 'type' => 'check', |
| 275 | + 'section' => 'rendering/advancedrendering', |
| 276 | + 'label-message' => 'articlefeedbackv5-disable-preference', |
| 277 | + ); |
| 278 | + } |
276 | 279 | return true; |
277 | 280 | } |
278 | 281 | |