Skip to content

Commit 31484b5

Browse files
committed
feat: remove unused variable
1 parent 1d443f6 commit 31484b5

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

inc/classes/Bootstrap.php

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,12 @@
1919
final class Bootstrap {
2020
use \J7\WpUtils\Traits\SingletonTrait;
2121

22-
/**
23-
* @var array
24-
* Store instances of classes
25-
*/
26-
public $settings = [];
27-
2822
/**
2923
* Constructor
3024
*/
3125
public function __construct() {
32-
$this->settings['FrontEnd\Entry'] = FrontEnd\Entry::instance();
33-
$this->settings['Admin\CPT'] = Admin\CPT::instance();
26+
FrontEnd\Entry::instance();
27+
Admin\CPT::instance();
3428

3529
\add_action( 'admin_enqueue_scripts', [ __CLASS__, 'admin_enqueue_script' ], 99 );
3630
\add_action( 'wp_enqueue_scripts', [ __CLASS__, 'frontend_enqueue_script' ], 99 );
@@ -76,8 +70,7 @@ public static function enqueue_script(): void {
7670
]
7771
);
7872

79-
$post_id = \get_the_ID();
80-
$permalink = \get_permalink( $post_id );
73+
$post_id = \get_the_ID();
8174

8275
\wp_localize_script(
8376
Plugin::$kebab,
@@ -88,7 +81,6 @@ public static function enqueue_script(): void {
8881
'ajaxUrl' => \untrailingslashit( \admin_url( 'admin-ajax.php' ) ),
8982
'userId' => \wp_get_current_user()->data->ID ?? null,
9083
'postId' => $post_id,
91-
'permalink' => \untrailingslashit( $permalink ),
9284
'APP_NAME' => Plugin::$app_name,
9385
'KEBAB' => Plugin::$kebab,
9486
'SNAKE' => Plugin::$snake,

0 commit comments

Comments
 (0)