Ticket #2000: 2000.5.diff
| File 2000.5.diff, 1.8 KB (added by , 10 years ago) |
|---|
-
global.wordpress.org/public_html/wp-content/mu-plugins/roles/cross-locale-pte.php
299 299 } 300 300 301 301 if ( GP::$permission->current_user_can( 'cross-pte', 'translation-set', $old_translation->translation_set_id ) ) { 302 // Set to waiting if a current translation exists by another user. 303 if ( intval( $old_translation->user_id ) !== intval( get_current_user_id() ) ) { 302 // Set to waiting if a current translation exists that was approved by another user. 303 $translation_owner_id = $old_translation->user_id_last_modified ?: $old_translation->user_id; 304 if ( intval( $old_translation->translation_owner_id ) !== intval( get_current_user_id() ) ) { 304 305 return 'waiting'; 305 306 } 306 307 } … … 401 402 402 403 if ( GP::$permission->user_can( $args['user'], 'cross-pte', 'translation-set', $translation->translation_set_id ) ) { 403 404 $current_translation = GP::$translation->find_one( array( 'translation_set_id' => $translation->translation_set_id, 'original_id' => $translation->original_id, 'status' => 'current' ) ); 404 if ( $current_translation && intval( $current_translation->user_id ) !== $args['user']->ID ) { 405 // Current translation was authored by someone else. Disallow setting to current. 405 $translation_owner_id = $current_translation->user_id_last_modified ?: $current_translation->user_id; 406 if ( $current_translation && intval( $translation_owner_id ) !== $args['user']->ID ) { 407 // Current translation was approved by someone else. Disallow setting to current. 406 408 return $current_translation_by_user[ $cache_key ] = false; 407 409 } 408 410
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)