HEX
Server: Apache
System: Linux uws7-179.cafe24.com 3.10.0-1160.119.1p.el7.x86_64 #1 SMP Thu Sep 11 14:15:01 KST 2025 x86_64
User: medikors (1589)
PHP: 7.3.1p1
Disabled: mysql_pconnect
Upload Files
File: /medikors/www/wp-content/plugins/happy-elementor-addons-pro/classes/class.marvin.php
<?php
namespace Happy_Addons_Pro;

defined( 'ABSPATH' ) || die();

class Marvin {

	public static function init() {
	    if ( hapro_is_elementor_version( '>=', '2.8.0' ) ) {
            add_action( 'elementor/editor/before_enqueue_scripts', [ __CLASS__, 'enqueue' ] );
        } else {
            add_action( 'elementor/preview/enqueue_scripts', [ __CLASS__, 'enqueue' ] );
        }
	}

	public static function enqueue() {
        if ( apply_filters( 'happyaddons_marvin_active', true ) && hapro_has_valid_license() ) {
            wp_enqueue_script(
                'marvin-ls',
                HAPPY_ADDONS_PRO_ASSETS . 'admin/js/marvin-ls.min.js',
                null,
                HAPPY_ADDONS_PRO_VERSION,
                true
            );

            if ( hapro_is_elementor_version( '>=', '2.8.0' ) ) {
                $src = HAPPY_ADDONS_PRO_ASSETS . 'admin/js/marvin-new.min.js';
                $dependencies = [ 'marvin-ls', 'elementor-editor' ];
            } else {
                $src = HAPPY_ADDONS_PRO_ASSETS . 'admin/js/marvin.min.js';
                $dependencies = [ 'marvin-ls' ];
            }

            wp_enqueue_script(
                'marvin',
                $src,
                $dependencies,
                HAPPY_ADDONS_PRO_VERSION,
                true
            );

			wp_localize_script(
				'marvin',
				'marvin',
				[
					'storagekey' => md5( 'LICENSE KEY' ),
					'identifier' => wp_create_nonce( 'ha-retainer' ),
					'serviceEndpoint' => admin_url( 'admin-ajax.php' )
				]
			);
        }
    }
}

Marvin::init();