current_page = $current_page; } /** * Returns `true` when on the frontend, * or when on the post overview, post edit or new post admin page. * * @returns boolean `true` when on the frontend, or when on the post overview, * post edit or new post admin page. */ public function is_met() { if ( ! \is_admin() ) { return true; } return \in_array( $this->current_page->get_current_admin_page(), [ 'edit.php', 'post.php', 'post-new.php' ], true ); } }