diff --git a/php/class-plugin.php b/php/class-plugin.php index 7aecee449..c2cc26833 100644 --- a/php/class-plugin.php +++ b/php/class-plugin.php @@ -422,6 +422,7 @@ private function is_notice_component( $component ) { */ public function init() { require_once ABSPATH . 'wp-admin/includes/plugin.php'; + $plugin = get_plugin_data( CLDN_CORE ); $location = $this->locate_plugin(); $this->slug = ! empty( $plugin['TextDomain'] ) ? $plugin['TextDomain'] : $location['dir_basename']; diff --git a/php/class-utils.php b/php/class-utils.php index cd5736069..0f774118b 100644 --- a/php/class-utils.php +++ b/php/class-utils.php @@ -331,6 +331,8 @@ protected static function table_installed() { * Install our custom table. */ public static function install() { + // Ensure that the plugin bootstrap is loaded. + get_plugin_instance()->init(); $sql = self::get_table_sql();