mirror of
https://gh.wpcy.net/https://github.com/4suredev/Avada-Custom-Visual-Builder-Button.git
synced 2026-04-25 04:02:18 +08:00
19 lines
557 B
PHP
19 lines
557 B
PHP
<?php
|
|
class Custom_visual_builder_button_updater {
|
|
protected $file;
|
|
protected $plugin;
|
|
protected $basename;
|
|
protected $active;
|
|
|
|
public function __construct( $file ) {
|
|
$this->file = $file;
|
|
add_action( 'admin_init', array( $this, 'set_plugin_properties' ) );
|
|
return $this;
|
|
}
|
|
|
|
public function set_plugin_properties() {
|
|
$this->plugin = get_plugin_data( $this->file );
|
|
$this->basename = plugin_basename( $this->file );
|
|
$this->active = is_plugin_active( $this->basename );
|
|
}
|
|
}
|