Make WordPress Core


Ignore:
Timestamp:
07/28/2013 10:28:18 PM (11 years ago)
Author:
nacin
Message:

When registering a post type, pass the correct argument for feeds to add_permastruct().

props butuzov, johnpbloch.
fixes #23302.

File:
1 edited

Legend:

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

    r24826 r24830  
    12711271        }
    12721272
    1273         add_permastruct( $post_type, "{$args->rewrite['slug']}/%$post_type%", $args->rewrite );
     1273        $permastruct_args = $args->rewrite;
     1274        $permastruct_args['feed'] = $permastruct_args['feeds'];
     1275        add_permastruct( $post_type, "{$args->rewrite['slug']}/%$post_type%", $permastruct_args );
    12741276    }
    12751277
Note: See TracChangeset for help on using the changeset viewer.