| | |
| | | <?php |
| | | namespace JVBase\registrar\helpers; |
| | | |
| | | use JVBase\meta\Meta; |
| | | use JVBase\registrar\Registrar; |
| | | use WP_Post; |
| | | |
| | | if (!defined('ABSPATH')) { |
| | | exit; |
| | | } |
| | |
| | | class MakeTimelineType { |
| | | protected string $slug; |
| | | protected string $postType; |
| | | protected Registrar $registrar; |
| | | public function __construct(string $slug, Registrar $registrar) { |
| | | public function __construct(string $slug) { |
| | | $this->slug = $slug; |
| | | $this->postType = jvbCheckBase($slug); |
| | | $this->registrar = $registrar; |
| | | |
| | | add_action('template_redirect', [$this, 'redirectChildToParent']); |
| | | } |