Making WordPress.org


Ignore:
Timestamp:
02/12/2024 07:08:54 AM (8 months ago)
Author:
dd32
Message:

Plugin Directory: Record when a plugin reviewer changes the plugin slug.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/admin/class-customizations.php

    r13112 r13203  
    545545                $data['post_name']
    546546            ) );
     547        }
     548
     549        // Record the slug change.
     550        $plugin = get_post( $postarr['ID'] );
     551        if ( $plugin && $plugin->post_name !== $data['post_name'] ) {
     552            Tools::audit_log( sprintf(
     553                "Slug changed from '%s' to '%s'.",
     554                $plugin->post_name,
     555                $data['post_name']
     556            ), $plugin->ID );
    547557        }
    548558
Note: See TracChangeset for help on using the changeset viewer.