Support » Plugin: Post Connector » Error when editing post with associated post connection

  • Resolved devonanderson

    (@devonanderson)


    When I am in the admin panel, and go to the edit page for a particular post that has an associated post connection, I get an error at the bottom of the page.

    Trying to get property of non-object in .../wp-admin/includes/post.php on line 1499

    The line in question is

    $sendback_text = get_post_type_object( $post->post_type )->labels->all_items;

    I’ve checked, and the post_type of this $post object is “sub_posts_pt_link”, which from a quick look in the database appears to be the post type of your “Active Connections”. I looked into your code, and you register a custom post type for “sub_posts_link”, but not for “sub_posts_pt_link”, I added a line underneath the first register_post_type, registering “sub_posts_pt_link” and it clears up this error.

    https://wordpress.org/plugins/post-connector/

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Error when editing post with associated post connection’ is closed to new replies.