Make WordPress Core

Ticket #26638: l10n.patch

File l10n.patch, 522 bytes (added by dshafik, 10 years ago)
  • wp-includes/l10n.php

    diff --git a/wp-includes/l10n.php b/wp-includes/l10n.php
    index 750e08d..e1dfab7 100644
    a b function get_locale() { 
    6565 * @return string Translated text
    6666 */
    6767function translate( $text, $domain = 'default' ) {
     68        if ($domain == 'default') {
     69                return apply_filters( 'gettext', $text, $text, $domain );
     70        }
     71
    6872        $translations = get_translations_for_domain( $domain );
    6973        return apply_filters( 'gettext', $translations->translate( $text ), $text, $domain );
    7074}