g::$assetManifest['extendify-launch.js'],
$scriptAsset['dependencies'],
$scriptAsset['version'],
true
);
$globalStylesId = \WP_Theme_JSON_Resolver::get_user_global_styles_post_id();
if (Config::$environment === 'DEVELOPMENT') {
// In dev, reset the variaton to the default.
wp_update_post([
'ID' => $globalStylesId,
'post_content' => wp_json_encode([
'styles' => [],
'settings' => [],
'isGlobalStylesUserThemeJSON' => true,
'version' => 2,
]),
]);
}
$skipSteps = defined('EXTENDIFY_SKIP_STEPS') ? constant('EXTENDIFY_SKIP_STEPS') : [];
$partnerData = PartnerData::getPartnerData();
$consentTermsUrlAI = isset($partnerData['consentTermsUrl']) ? \esc_url_raw($partnerData['consentTermsUrl']) : '';
// Always shows on devmode, and won't show if disabled, or the consent url is missing.
if (!array_key_exists('showAICopy', $partnerData) && Config::$environment !== 'DEVELOPMENT') {
$skipSteps[] = 'business-information';
}
\wp_add_inline_script(
Config::$slug . '-launch-scripts',
'window.extOnbData = ' . \wp_json_encode([
'globalStylesPostID' => $globalStylesId,
'editorStyles' => \get_block_editor_settings([], null),
'site' => \esc_url_raw(\get_site_url()),
'adminUrl' => \esc_url_raw(\admin_url()),
'pluginUrl' => \esc_url_raw(EXTENDIFY_BASE_URL),
'home' => \esc_url_raw(\get_home_url()),
'root' => \esc_url_raw(\rest_url(Config::$slug . '/' . Config::$apiVersion)),
'config' => Config::$config,
'wpRoot' => \esc_url_raw(\rest_url()),
'nonce' => \wp_create_nonce('wp_rest'),
'partnerLogo' => \esc_attr(PartnerData::$logo),
'partnerName' => \esc_attr(PartnerData::$name),
'partnerId' => \esc_attr(PartnerData::$id),
'partnerSkipSteps' => $skipSteps,
'consentTermsUrlAI' => $consentTermsUrlAI,
'showLocalizedCopy' => array_key_exists('showLocalizedCopy', $partnerData),
'devbuild' => \esc_attr(Config::$environment === 'DEVELOPMENT'),
'version' => Config::$version,
'siteId' => \get_option('extendify_site_id', ''),
// Only send insights if they have opted in explicitly.
'insightsEnabled' => defined('EXTENDIFY_INSIGHTS_URL'),
'activeTests' => \get_option('extendify_active_tests', []),
'wpLanguage' => \get_locale(),
'wpVersion' => \get_bloginfo('version'),
'siteCreatedAt' => get_user_option('user_registered', 1),
'oldPagesIds' => $this->getLaunchCreatedPages(),
]),
'before'
);
\wp_set_script_translations(Config::$slug . '-launch-scripts', 'extendify-local', EXTENDIFY_PATH . 'languages/js');
\wp_enqueue_style(
Config::$slug . '-launch-styles',
EXTENDIFY_BASE_URL . 'public/build/' . Config::$assetManifest['extendify-launch.css'],
[],
Config::$version
);
}
/**
* Returns all the pages created by Extendify.
*
* @return array
*/
public static function getLaunchCreatedPages()
{
$posts = get_posts([
'numberposts' => -1,
'post_status' => 'publish',
'post_type' => 'page',
// only return the ID field.
'fields' => 'ids',
]);
return array_values(array_filter(array_map(function ($post) {
return get_post_meta($post, 'made_with_extendify_launch') ? $post : false;
}, $posts)));
}
}
Fatal error: Uncaught Error: Class 'Extendify\Launch\Admin' not found in /var/www/html/838solucoes.com.br/web/wp-content/plugins/extendify/bootstrap.php:44
Stack trace:
#0 /var/www/html/838solucoes.com.br/web/wp-content/plugins/extendify/extendify.php(63): require()
#1 /var/www/html/838solucoes.com.br/web/wp-content/plugins/extendify/extendify.php(74): Extendify->__invoke()
#2 /var/www/html/838solucoes.com.br/web/wp-includes/class-wp-hook.php(324): {closure}('')
#3 /var/www/html/838solucoes.com.br/web/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array)
#4 /var/www/html/838solucoes.com.br/web/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#5 /var/www/html/838solucoes.com.br/web/wp-settings.php(506): do_action('plugins_loaded')
#6 /var/www/html/838solucoes.com.br/web/wp-config.php(84): require_once('/var/www/html/8...')
#7 /var/www/html/838solucoes.com.br/web/wp-load.php(50): require_once('/var/www/html/8...')
#8 /var/www/html/838solucoes.com.br/web/wp-blog-header.php(13): require_once('/var/www/ in /var/www/html/838solucoes.com.br/web/wp-content/plugins/extendify/bootstrap.php on line 44