@@ -63,8 +63,6 @@ class Init {
63
63
* Bind hooks
64
64
*/
65
65
public function __construct () {
66
- $ this ->data = get_plugin_data ( __FILE__ );
67
-
68
66
static ::$ dependencies = [
69
67
'woocommerce.php ' => __ ( 'WooCommerce ' , 'woocommerce ' ),
70
68
'woocommerce-checkout-manager.php ' => __ ( 'Checkout Manager for WooCommerce ' , 'woocommerce-checkout-manager ' ),
@@ -76,7 +74,7 @@ public function __construct() {
76
74
77
75
add_filter ( 'register_translatable_package ' , [ $ this , 'register_translatable_package ' ], 12 );
78
76
79
- add_action ( 'plugins_loaded ' , [ $ this , 'textdomain ' ] );
77
+ add_action ( 'init ' , [ $ this , 'textdomain ' ] );
80
78
add_action ( 'init ' , [ $ this , 'register_block ' ] );
81
79
add_action ( 'init ' , [ $ this , 'register_meta ' ] );
82
80
@@ -178,6 +176,8 @@ public function check_dependencies(): void {
178
176
* @return void
179
177
*/
180
178
public function textdomain (): void {
179
+ $ this ->data = get_plugin_data ( __FILE__ );
180
+
181
181
load_plugin_textdomain ( 'aidonations ' , false , basename ( __DIR__ ) . '/languages ' );
182
182
}
183
183
0 commit comments