Changeset 9086
- Timestamp:
- 07/30/2019 09:11:33 AM (5 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content/plugins/theme-directory
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/theme-directory/class-wporg-themes-upload.php
r8794 r9086 774 774 ) ); 775 775 776 // Theme review team auto-approves theme-updates, so mark the theme as live immediately, without sending additional email 776 $theme_is_older_than_two_years = strtotime( $this->theme_post->post_modified ) < strtotime( '-2 years' ); 777 778 // Theme review team auto-approves theme-updates, so mark the theme as live immediately, if last updated within two years. 777 779 // Note that this only applies to new ticket creation, so it won't happen on themes with existing outstanding tickets 778 if ( $this->trac_ticket->priority == 'theme update' ) {780 if ( ! $theme_is_older_than_two_years && $this->trac_ticket->priority == 'theme update' ) { 779 781 $this->trac->ticket_update( $ticket_id, 'Theme Update for existing Live theme - automatically reviewed', array( 'action' => 'review' ), false ); 780 782 $this->trac->ticket_update( $ticket_id, 'Theme Update for existing Live theme - automatically approved', array( 'action' => 'approve_and_live' ), false ); -
sites/trunk/wordpress.org/public_html/wp-content/plugins/theme-directory/jobs/class-trac-sync.php
r6295 r9086 114 114 'posts_per_page' => - 1, 115 115 'meta_query' => [ 116 [116 'trac_sync_ticket_id' => [ 117 117 'value' => $ticket_id, 118 118 'compare' => 'IN', -
sites/trunk/wordpress.org/public_html/wp-content/plugins/theme-directory/query-modifications.php
r2920 r9086 108 108 } 109 109 110 // Unless a specific theme, or author is being requested, limit results to the last 2 years. 111 if ( empty( $query->query_vars['name'] ) && empty( $query->query_vars['author_name'] ) && ! in_array( $query->query_vars['browse'], array( 'favorites', 'new', 'updated' ) ) ) { 110 // Unless a specific theme/author is being requested, or it's an internal query, limit results to the last 2 years. 111 if ( 112 empty( $query->query_vars['name'] ) && 113 empty( $query->query_vars['author_name'] ) && 114 ! in_array( $query->query_vars['browse'], array( 'favorites', 'new', 'updated' ) ) && 115 empty( $query->query_vars['meta_query']['trac_sync_ticket_id'] ) // jobs/class-trac-sync.php - Always needs to find the post, and looks up via a meta search. 116 ) { 112 117 $query->query_vars['date_query']['recent_themes_only'] = array( 113 118 'column' => 'post_modified', … … 117 122 118 123 // Prioritize translated themes for localized requests, except when viewing a specific ordered themes. 119 if ( 'en_US' !== get_locale() && ! in_array( $query->query_vars['browse'], array( 'favorites', 'new', 'updated' ) ) ) { 124 if ( 125 'en_US' !== get_locale() && 126 ! in_array( $query->query_vars['browse'], array( 'favorites', 'new', 'updated' ) ) 127 ) { 120 128 add_filter( 'posts_clauses', 'wporg_themes_prioritize_translated_posts_clauses' ); 121 129 }
Note: See TracChangeset
for help on using the changeset viewer.