Make WordPress Core

Opened 13 years ago

Closed 13 years ago

#17416 closed defect (bug) (fixed)

Use wp_remote_retrieve_* functions where appropriate

Reported by: aaroncampbell's profile aaroncampbell Owned by: nacin's profile nacin
Milestone: 3.2 Priority: normal
Severity: normal Version: 3.2
Component: Administration Keywords: has-patch
Focuses: Cc:

Description (last modified by aaroncampbell)

There are quite a few places where we're not using these:

  • wp_remote_retrieve_headers()
  • wp_remote_retrieve_header()
  • wp_remote_retrieve_response_code()
  • wp_remote_retrieve_response_message()
  • wp_remote_retrieve_body().

Attachments (2)

17416.diff (1.1 KB) - added by aaroncampbell 13 years ago.
Also removes useless $raw_response var
17416.2.diff (12.1 KB) - added by aaroncampbell 13 years ago.

Download all attachments as: .zip

Change History (9)

13 years ago

Also removes useless $raw_response var

#1 @aaroncampbell
13 years ago

  • Component changed from General to Administration
  • Keywords has-patch added
  • Milestone changed from Awaiting Review to 3.2
  • Version set to 3.2

#2 follow-up: @nacin
13 years ago

  • Owner set to nacin
  • Status changed from new to accepted

Figured you'd notice that :)

#3 in reply to: ↑ 2 @westi
13 years ago

Replying to nacin:

Figured you'd notice that :)

tsk tsk! ;)

#4 @aaroncampbell
13 years ago

Old habits die hard? It looks like there are other places in core where this should be done as well:

  • wp-admin/includes/plugin-install.php
  • wp-admin/includes/theme.php
  • wp-include/class-feed.php
  • wp-include/class-wp-http-ixr-client.php
  • wp-include/comment.php
  • wp-include/functions.php
  • wp-include/rss.php
  • wp-include/update.php

I'll just expand this ticket and make a new patch.

#5 @aaroncampbell
13 years ago

  • Description modified (diff)
  • Keywords has-patch removed
  • Summary changed from Browser nag should use built-in HTTP functions to Use wp_remote_retrieve_* functions where appropriate

#6 @aaroncampbell
13 years ago

  • Keywords has-patch added

I can't guarantee I caught them all, but that's all that I saw.

#7 @nacin
13 years ago

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

In [17928]:

Use wp_remote_retrieve_* helper functions instead of the raw HTTP response array. props aaroncampbell, fixes #17416.

Note: See TracTickets for help on using tickets.