Remove unneccessary check for wp_set_script_translations

This commit is contained in:
Justin Foell
2020-11-27 16:46:47 -06:00
parent 9b151231ee
commit 71eee61a73
+6 -8
View File
@@ -220,14 +220,12 @@ class WPStrava {
$block->register_block();
}
if ( function_exists( 'wp_set_script_translations' ) ) {
/**
* May be extended to wp_set_script_translations( 'my-handle', 'my-domain',
* plugin_dir_path( MY_PLUGIN ) . 'languages' ) ). For details see
* https://make.wordpress.org/core/2018/11/09/new-javascript-i18n-support-in-wordpress/
*/
wp_set_script_translations( 'wp-strava-block', 'wp-strava' );
}
/**
* May be extended to wp_set_script_translations( 'my-handle', 'my-domain',
* plugin_dir_path( MY_PLUGIN ) . 'languages' ) ). For details see
* https://make.wordpress.org/core/2018/11/09/new-javascript-i18n-support-in-wordpress/
*/
wp_set_script_translations( 'wp-strava-block', 'wp-strava' );
}
}