Ticket #5498 (closed defect: fixed)

Opened 1 year ago

Last modified 1 year ago

Manage => Pages may produce orphaned page

Reported by: hailin Assigned to: hailin
Priority: normal Milestone: 2.5
Component: General Version: 2.5
Severity: normal Keywords: has-patch
Cc:

Description

because array_splice may not preserve the original numeric index, it causes our pages display to produce orphaned pages.

Attachments

5498_pages.diff (510 bytes) - added by hailin on 12/20/07 02:28:03.
patch
5498_fix_bad_pages.diff (0.7 kB) - added by hailin on 12/21/07 03:50:32.
fix bad pages whose parent = itself
5498_pages_2.diff (1.8 kB) - added by hailin on 12/21/07 17:47:15.
make the behavior completely the same as the original walk class

Change History

12/20/07 01:19:34 changed by hailin

  • owner changed from anonymous to hailin.
  • status changed from new to assigned.

In most cases, array_splice preserves index, yet, by spec, it may not. When it doesn't, that is causing problems. To fix this, we set $i to -1, thus when ++ed, it starts from 0.

12/20/07 02:28:03 changed by hailin

  • attachment 5498_pages.diff added.

patch

12/20/07 04:11:52 changed by lloydbudd

  • keywords set to has-patch.
  • version set to 2.4.
  • milestone changed from 2.5 to 2.4.

12/20/07 05:29:52 changed by ryan

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

(In [6427]) Orphaned page fix from hailin. fixes #5498

12/20/07 18:25:47 changed by hailin

  • status changed from closed to reopened.
  • resolution deleted.

12/20/07 18:26:37 changed by hailin

patch walk class to make similar index change. It is in 5498_pages_2.diff

12/21/07 03:50:32 changed by hailin

  • attachment 5498_fix_bad_pages.diff added.

fix bad pages whose parent = itself

12/21/07 03:51:52 changed by hailin

I've put all three fix together. All three should go into wporg as each fixes one different issue.

12/21/07 17:47:15 changed by hailin

  • attachment 5498_pages_2.diff added.

make the behavior completely the same as the original walk class

12/21/07 18:49:20 changed by ryan

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

(In [6456]) Page walker fixes from hailin. fixes #5498

12/21/07 18:51:02 changed by ryan

Some extra stuff got in there. Reverted with [6457].