Skip to content

Commit 35bb2d1

Browse files
Merge pull request #1045 from cloudinary/optimize/meta-box-register_handlers
Move register_handlers to init in class-meta-box.php
2 parents f44aa0f + f2eeb7f commit 35bb2d1

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

php/class-meta-box.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,6 @@ public function __construct( Plugin $plugin ) {
3737
$this->plugin = $plugin;
3838

3939
add_action( 'init', array( $this, 'init_hook' ) );
40-
41-
$this->register_handlers();
4240
}
4341

4442
/**
@@ -48,6 +46,8 @@ public function __construct( Plugin $plugin ) {
4846
*/
4947
public function init_hook() {
5048
add_action( 'add_meta_boxes', array( $this, 'register_meta_box' ) );
49+
50+
$this->register_handlers();
5151
}
5252

5353
/**

0 commit comments

Comments
 (0)