Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add tag_base to list of untrailingslashed options, and standardize th…

…e unslashing. Prevents /mytags//tagname/

git-svn-id: http://svn.automattic.com/wordpress/trunk@6153 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information...
commit 0fb4233fdf8f3a00147bcc7724c8503b2947e06a 1 parent c005340
markjaquith authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 wp-includes/functions.php
4 wp-includes/functions.php
View
@@ -218,8 +218,8 @@ function get_option($setting) {
if ( 'home' == $setting && '' == $value )
return get_option('siteurl');
- if ( 'siteurl' == $setting || 'home' == $setting || 'category_base' == $setting )
- $value = preg_replace('|/+$|', '', $value);
+ if ( in_array($setting, array('siteurl', 'home', 'category_base', 'tag_base')) )
+ $value = untrailingslashit($value);
return apply_filters( 'option_' . $setting, maybe_unserialize($value) );
}
Please sign in to comment.
Something went wrong with that request. Please try again.