Ticket #5834 (closed defect: fixed)

Opened 7 months ago

Last modified 7 months ago

Errneous variable name in comments-template.php

Reported by: reinkim Assigned to: anonymous
Priority: normal Milestone: 2.5
Component: General Version:
Severity: critical Keywords:
Cc:

Description

in [6716],

	585 function pings_open( $post_id=NULL ) { 
 	586 
 	587	    $_post = get_post($post_id); 
 	588	 
 	589	    $open = ( 'open' == $post->ping_status ); 
 	590	    return apply_filters( 'pings_open', $open, $post_id ); 

$post in line 585 should be $_post.

This variable lookup-failure causes trackback failure

Change History

02/13/08 03:48:21 changed by reinkim

This function is located in wp-includes/comment-template.php

02/13/08 04:24:33 changed by DD32

$post in line 585 should be $_post.

Looking at that, Its supposed to be $post_id, As in, You pass the post id in, then it fetches that post, and checks the ping status.

02/13/08 06:39:45 changed by ryan

  • status changed from new to closed.
  • resolution set to fixed.

(In [6802]) Fix variable name typo. Props reinkim. fixes #5834

02/13/08 06:40:23 changed by ryan

  • milestone changed from 2.6 to 2.5.

If get_post() is passed a null post_id it will use the global post.