Make WordPress Core

Opened 12 years ago

Last modified 5 years ago

#23020 new defect (bug)

wp.getPageList should act like wp.getPages

Reported by: daniloercoli's profile daniloercoli Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.2
Component: XML-RPC Keywords: has-patch needs-refresh dev-feedback
Focuses: Cc:


I know that wp.getPageList is obsolete, but I think it should act like wp.getPages At the moment wp.getPageList returns even the trashed pages and doesn't return the status of the page.

The weird behavior i've seen with wp.getPageList on a third-party client is shown below:

  • Refresh the pages list.
  • The Page 'A' is in the list.
  • Select the page 'A' and delete it.
  • Refresh the pages list and the page is still there. Doh!

Attachments (1)

wp_getPageList.diff (2.1 KB) - added by daniloercoli 12 years ago.

Download all attachments as: .zip

Change History (4)

#1 @SergeyBiryukov
12 years ago

  • Version changed from trunk to 2.2

#2 @redsweater
12 years ago

It seems like it would be harmless to add additional information e.g. the status of a page, but changing the behavior to no longer include pages that previously were included seems dangerous to existing clients. Is it possible some clients are relying on the old functionality to e.g. include trashed pages?

You might consider adding a 4th, optional parameter to wp.getPageList that would be suitable for limiting the statuses of pages that are returned. Then again, perhaps I'm overthinking it, but do at least think about whether clients may be depending on the generous return values of this method.

#3 @chriscct7
9 years ago

  • Keywords needs-refresh dev-feedback added; mobile removed
  • Severity changed from minor to normal
Note: See TracTickets for help on using tickets.