Skip to content

Commit

Permalink
Merge pull request #644 from newfold-labs/fix/PRESS10-52
Browse files Browse the repository at this point in the history
Fix Change the path where it should look for the theme-i18.json file for different translations
  • Loading branch information
wpscholar authored Jan 22, 2025
2 parents b901f54 + 6ffe714 commit 5cc4cb8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions includes/RestApi/Themes/ThemeVariationsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ public function get_update_diy_global_style_variation_args() {
* @return string
*/
private static function translate( $theme_json, $domain = 'default' ) {
$i18n_schema = wp_json_file_decode( __DIR__ . '/theme-i18n.json' );

$path = wp_normalize_path( realpath( ABSPATH . WPINC ) ) . '/theme-i18n.json';
$i18n_schema = wp_json_file_decode( $path );
return translate_settings_using_i18n_schema( $i18n_schema, $theme_json, $domain );
}

Expand Down

0 comments on commit 5cc4cb8

Please sign in to comment.