Currently the start() method needs to be used to pass the post type arguments or it must be done in the constructor. While I was writing a tutorial on how to create a custom post type with the framework, I found this is not intuitive and it should be able to do in the setUp() method.
For that, the timing of the hook that triggers setUp() method will be changed from wp_loaded to init. Also the setUp() method currently is only loaded in the admin area ( with the check of is_admin() ) but this will be not checked.
This is a minor change but may affect some users using the post type factory class.
Currently the
start()
method needs to be used to pass the post type arguments or it must be done in the constructor. While I was writing a tutorial on how to create a custom post type with the framework, I found this is not intuitive and it should be able to do in thesetUp()
method.For that, the timing of the hook that triggers
setUp()
method will be changed fromwp_loaded
toinit
. Also thesetUp()
method currently is only loaded in the admin area ( with the check of is_admin() ) but this will be not checked.This is a minor change but may affect some users using the post type factory class.