Making WordPress.org

Changeset 13014


Ignore:
Timestamp:
12/05/2023 06:47:15 AM (10 months ago)
Author:
dd32
Message:

Helpscout: Plugins+Themes widget: More whitespace and Actually link to pending plugin zips (again).

See #7351.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/api.wordpress.org/public_html/dotorg/helpscout/plugins-themes.php

    r13013 r13014  
    141141    foreach ( $post_ids as $post_id ) {
    142142        $post          = get_post( $post_id );
    143         $type          = 'theme'; // plugin set below.
     143        $type          = ( 'plugin' === $post->post_type ) ? 'plugin' : 'theme';
    144144        $post_status   = '';
    145145        $style         = 'color: green;';
    146146        $reviewer      = false;
    147147        $last_modidied = $post->post_modified_gmt;
    148 
    149         if ( 'plugin' === $post->post_type ) {
    150             $type = 'plugin';
    151 
     148        $download_link = "https://downloads.wordpress.org/{$type}/{$post->post_name}.latest-stable.zip";
     149
     150        if ( 'plugin' === $type ) {
    152151            if ( $post->assigned_reviewer ) {
    153152                $reviewer_user = get_user_by( 'id', $post->assigned_reviewer );
     
    171170        }
    172171
    173         $download_link      = "https://downloads.wordpress.org/{$type}/{$post->post_name}.latest-stable.zip";
    174172        $last_updated       = human_time_diff( strtotime( $last_modified ), time() );
    175173        $short_last_updated = str_ireplace(
     
    229227        printf(
    230228            '<li>
    231                 <a href="%1$s" style="%2$s">%3$s</a>
     229                <a href="%1$s" style="%2$s">%3$s</a>&nbsp;
    232230                <a href="%4$s" style="%2$s">#</a>&nbsp;
    233                 <a href="%5$s" style="%2$s">ↆ</a>&nbsp;%6$s
    234                 <br><span style="%2$s">%7$s</span>&nbsp;
     231                <a href="%5$s" style="%2$s">ↆ</a>&nbsp;%6$s<br>
     232                <span style="%2$s">%7$s</span>&nbsp;
    235233                %8$s
    236234            </li>',
Note: See TracChangeset for help on using the changeset viewer.