Make WordPress Core


Ignore:
Timestamp:
02/10/2021 05:38:23 AM (4 years ago)
Author:
peterwilsoncc
Message:

Canonical: Rename wp_force_plain_ugly_permalink() to match UI terminology.

Rename wp_force_plain_ugly_permalink() to wp_force_plain_post_permalink() to match terminology used in the WordPress dashboard.

Follow up to [50132].
Props SergeyBiryukov.
Fixes #5272.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/post.php

    r50255 r50282  
    13581358    $original_name   = $post->post_name;
    13591359
    1360     // Hack: get_permalink() would return ugly permalink for drafts, so we will fake that our post is published.
     1360    // Hack: get_permalink() would return plain permalink for drafts, so we will fake that our post is published.
    13611361    if ( in_array( $post->post_status, array( 'draft', 'pending', 'future' ), true ) ) {
    13621362        $post->post_status = 'publish';
Note: See TracChangeset for help on using the changeset viewer.