WordPress.org

Ready to get started?Download WordPress

Forums

Auto Post Thumbnail
[resolved] a remark on a code comment (2 posts)

  1. birgire
    Member
    Posted 1 year ago #

    Great plugin!

    I have just a minor remark about this code comment:

    function apt_check_required_transition($new_status='', $old_status='', $post='') {
        global $post_ID; // Using the post id from global reference since it is not available in $post object. Strange!

    I think the reason for this is that you are using

    add_action('transition_post_status', 'apt_check_required_transition');

    instead of

    add_action('transition_post_status', 'apt_check_required_transition', 10, 3);

    to activate it, so the input parameters $old_status and $post are empty in your case.

    cheers

    http://wordpress.org/extend/plugins/auto-post-thumbnail/

  2. tariquesani
    Member
    Plugin Author

    Posted 11 months ago #

    Version 3.3.3 incorporates this - thanks

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.