Make WordPress Core

Ticket #14147: 14147.diff

File 14147.diff, 3.6 KB (added by jacobsantos, 15 years ago)

Update more coding standard violations.

  • capabilities.php

     
    10791079function current_user_can_for_blog( $blog_id, $capability ) {
    10801080        $current_user = wp_get_current_user();
    10811081
    1082     if ( is_multisite() && is_super_admin() )
     1082        if ( is_multisite() && is_super_admin() )
    10831083                return true;
    10841084
    10851085        if ( empty( $current_user ) )
  • category-template.php

     
    731731                break;
    732732        endswitch;
    733733
    734     if ( $filter )
     734        if ( $filter )
    735735                return apply_filters( 'wp_generate_tag_cloud', $return, $tags, $args );
    736     else
     736        else
    737737                return $return;
    738738}
    739739
  • cron.php

     
    9090
    9191        $now = time();
    9292
    93     if ( $timestamp >= $now )
    94         $timestamp = $now + $interval;
    95     else
    96         $timestamp = $now + ($interval - (($now - $timestamp) % $interval));
     93        if ( $timestamp >= $now )
     94                $timestamp = $now + $interval;
     95        else
     96                $timestamp = $now + ($interval - (($now - $timestamp) % $interval));
    9797
    9898        wp_schedule_event( $timestamp, $recurrence, $hook, $args );
    9999}
  • functions.php

     
    669669function delete_transient( $transient ) {
    670670        global $_wp_using_ext_object_cache;
    671671
    672     do_action( 'delete_transient_' . $transient, $transient );
     672        do_action( 'delete_transient_' . $transient, $transient );
    673673
    674674        if ( $_wp_using_ext_object_cache ) {
    675675                $result = wp_cache_delete( $transient, 'transient' );
     
    757757function set_transient( $transient, $value, $expiration = 0 ) {
    758758        global $_wp_using_ext_object_cache;
    759759
    760     $value = apply_filters( 'pre_set_transient_' . $transient, $value );
     760        $value = apply_filters( 'pre_set_transient_' . $transient, $value );
    761761
    762762        if ( $_wp_using_ext_object_cache ) {
    763763                $result = wp_cache_set( $transient, $value, 'transient', $expiration );
     
    37843784function set_site_transient( $transient, $value, $expiration = 0 ) {
    37853785        global $_wp_using_ext_object_cache;
    37863786
    3787     $value = apply_filters( 'pre_set_site_transient_' . $transient, $value );
     3787        $value = apply_filters( 'pre_set_site_transient_' . $transient, $value );
    37883788
    37893789        if ( $_wp_using_ext_object_cache ) {
    37903790                $result = wp_cache_set( $transient, $value, 'site-transient', $expiration );
  • link-template.php

     
    22282228 * @uses wp_get_shortlink()
    22292229 */
    22302230function wp_shortlink_header() {
    2231     if ( headers_sent() )
     2231        if ( headers_sent() )
    22322232                return;
    22332233
    22342234        $shortlink = wp_get_shortlink(0, 'query');
  • taxonomy.php

     
    996996                        $order = '';
    997997                        $selects = array('COUNT(*)');
    998998        }
    999     $select_this = implode(', ', apply_filters( 'get_terms_fields', $selects, $args ));
     999        $select_this = implode(', ', apply_filters( 'get_terms_fields', $selects, $args ));
    10001000
    10011001        $query = "SELECT $select_this FROM $wpdb->terms AS t INNER JOIN $wpdb->term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy IN ($in_taxonomies) $where $orderby $order $limit";
    10021002