Changeset 6287 for sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/class-plugin-i18n.php
- Timestamp:
- 12/19/2017 04:22:37 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/class-plugin-i18n.php
r5982 r6287 64 64 * 65 65 * @access private 66 *67 66 */ 68 67 private function __construct() { … … 237 236 $translation_set_id = $wpdb->get_var( $wpdb->prepare( 238 237 'SELECT id FROM ' . GLOTPRESS_TABLE_PREFIX . 'translation_sets WHERE project_id = %d AND locale = %s', 239 $branch_id, $locale ) ); 238 $branch_id, $locale 239 ) ); 240 240 241 241 if ( empty( $translation_set_id ) ) { … … 456 456 $translation_sets = $this->cache_get( $post->post_name, $branch, $cache_suffix ); 457 457 if ( false === $translation_sets ) { 458 $api_url = esc_url_raw( 'https://translate.wordpress.org/api/projects/wp-plugins/' . $post->post_name . '/' . $branch, [ 'https' ] );458 $api_url = esc_url_raw( 'https://translate.wordpress.org/api/projects/wp-plugins/' . $post->post_name . '/' . $branch, [ 'https' ] ); 459 459 $response = wp_remote_get( $api_url ); 460 460 … … 462 462 $translation_sets = []; 463 463 } else { 464 $result = json_decode( wp_remote_retrieve_body( $response ) );464 $result = json_decode( wp_remote_retrieve_body( $response ) ); 465 465 $translation_sets = isset( $result->translation_sets ) ? $result->translation_sets : []; 466 466 }
Note: See TracChangeset
for help on using the changeset viewer.