mirror of
git://develop.git.wordpress.org/
synced 2025-02-27 10:02:43 +01:00
Get rid of stray comma. fixes #10977. props kevinB
git-svn-id: https://develop.svn.wordpress.org/trunk@12327 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
5831826b77
commit
dd1d1be280
@ -746,8 +746,9 @@ function wp_list_pages($args = '') {
|
||||
// sanitize, mostly to keep spaces out
|
||||
$r['exclude'] = preg_replace('/[^0-9,]/', '', $r['exclude']);
|
||||
|
||||
// Allow plugins to filter an array of excluded pages
|
||||
$r['exclude'] = implode(',', apply_filters('wp_list_pages_excludes', explode(',', $r['exclude'])));
|
||||
// Allow plugins to filter an array of excluded pages (but don't put a nullstring into the array)
|
||||
$exclude_array = ( $r['exclude'] ) ? explode(',', $r['exclude']) : array();
|
||||
$r['exclude'] = implode( ',', apply_filters('wp_list_pages_excludes', $exclude_array) );
|
||||
|
||||
// Query pages.
|
||||
$r['hierarchical'] = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user