Making WordPress.org

Changeset 9512


Ignore:
Timestamp:
02/19/2020 05:09:16 AM (5 years ago)
Author:
dd32
Message:

Trac: Actually show the Github PR section for unauthenticated users, the element this was attached to previously relied upon the current user being able to upload a patch, or another user having already done so.

See [9510], #4903.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/style/trac/wp-trac.js

    r9511 r9512  
    15991599
    16001600            function renderAddSection() {
    1601                 // Add the Pull Requests section.
    1602                 $( '#attachments' ).append(
     1601                // Add the Pull Requests section, #attachments is only present if authenticated or there exists uploads.
     1602                var afterDiv = $( '#attachments' );
     1603                if ( ! afterDiv.length ) {
     1604                    afterDiv = $( '#commits' );
     1605                }
     1606
     1607                afterDiv.after(
    16031608                    '<div id="github-prs">' +
    16041609                        '<h3 class="foldable"><a id="section-pr" href="#section-pr">Pull Requests <span class="trac-count hidden">(<span></span>)</span></a></h3>' +
Note: See TracChangeset for help on using the changeset viewer.