Making WordPress.org


Ignore:
Timestamp:
02/10/2022 09:38:45 AM (3 years ago)
Author:
dd32
Message:

Trac: Add the ability to include Tickets that you've added a GitHub PR to, in the 'my patches' reports.

See https://core.trac.wordpress.org/my-patches + https://meta.trac.wordpress.org/report/12
Fixes #5596.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/api.wordpress.org/public_html/dotorg/trac/pr/webhook.php

    r11099 r11544  
    8181        // Step 3. If not in DB, or $pr_data->trac_ticket isn't yet in the DB, add a new row of it.
    8282        if ( $pr_data->trac_ticket && ( ! $existing_refs || ! $matched_existing_ref ) ) {
     83
     84            $user_id = (int) find_wporg_user_by_github( $pr_data->user->name, 'ID' );
     85
    8386            $wpdb->insert(
    8487                'trac_github_prs',
     
    9194                    'pr'           => $pr_number,
    9295                    'data'         => json_encode( $_pr_data_no_ticket ),
     96                    'author'       => $user_id,
    9397                ]
    9498            );
Note: See TracChangeset for help on using the changeset viewer.