WP_Theme: If no 'Domain Path' header is specified, default to looking in the /languages directory. see #20103, see #20448.

git-svn-id: http://core.svn.wordpress.org/trunk@20945 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
nacin 2012-05-27 16:42:38 +00:00
parent c0339644ea
commit 9355ae1abe
1 changed files with 2 additions and 0 deletions

View File

@ -1025,6 +1025,8 @@ final class WP_Theme implements ArrayAccess {
$path = $this->get_stylesheet_directory();
if ( $domainpath = $this->get('DomainPath') )
$path .= $domainpath;
else
$path .= '/languages';
$this->textdomain_loaded = load_theme_textdomain( $textdomain, $path );
return $this->textdomain_loaded;