Skip to content

Commit d4b69dd

Browse files
committed
bugfix i18n: force-load theme textdomain from correct path and at correct time
1 parent 3a853af commit d4b69dd

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

themes/Capitularia/functions.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,12 @@
3535
* plugin.
3636
*/
3737

38-
load_theme_textdomain ('capitularia', WP_CONTENT_DIR . '/dist/languages/');
38+
add_action('init', function () {
39+
load_textdomain(
40+
'capitularia',
41+
get_template_directory() . '/dist/languages/' . determine_locale() . '.mo'
42+
);
43+
});
3944

4045
/*
4146
* These strings are defined somewhere inside Wordpress. Because we want to

0 commit comments

Comments
 (0)