WordPress.org

Make WordPress Core

Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#5961 closed defect (bug) (fixed)

Fix some notices

Reported by: nbachiyski Owned by:
Milestone: 2.5 Priority: normal
Severity: normal Version:
Component: General Keywords: notices has-patch needs-testing
Focuses: Cc:

Description

Last night I turned debugging on and fought with some notices.

In most of the places there are just issets added, but at some places there are more complicated cases, which need review and some testing.

Attachments (2)

notices.diff (14.6 KB) - added by nbachiyski 7 years ago.
5961.diff (966 bytes) - added by fitztrev 7 years ago.
Reverting the change to wp-inc/canonical.php makes it work.

Download all attachments as: .zip

Change History (8)

@nbachiyski7 years ago

comment:1 @ryan7 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [6983]) Notice fixes from nbachiyski. fixes #5961

comment:2 @fitztrev7 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

After r6983, the links on my site that used my old permalink structure result in 404s. Prior to this change, the old links would automatically redirect to the new permalink structure and find the post correctly.

@fitztrev7 years ago

Reverting the change to wp-inc/canonical.php makes it work.

comment:3 @ryan7 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

(In [6998]) Revert changes to canonical that broke redirects. Props fitztrev. fixes #5961

comment:4 @nbachiyski7 years ago

The problem is in these two lines:

$original['query'] = isset($redirect['query'])? $redirect['query'] : false; 
$original['port'] = isset($redirect['port'])? $redirect['port'] : false; 

Here I am filling $original with $redirect's values.

Copy-paste after midnight should be avoided :-)

comment:5 @darkdragon7 years ago

  • Milestone changed from 2.6 to 2.5

comment:6 @andy7 years ago

sanitize_post changes broke filtering of new posts, reverted in [7161]

Note: See TracTickets for help on using tickets.