WordPress.org

Make WordPress Core

#23674 closed defect (bug) (fixed)

Twenty Eleven: twentyeleven_url_grabber() should not be pluggable

Reported by: nacin Owned by:
Milestone: 3.6 Priority: normal
Severity: normal Version: 3.6
Component: Bundled Theme Keywords:
Focuses: Cc:

Description

Looking at [23474]. In the past, we've had two types of functions for default themes:

  1. It's a function that gets used in a theme. Should be pluggable.
  1. It's a function that gets used as a hook callback. No need to be pluggable.

However, twentyeleven_url_grabber() is a utility function. It wasn't an oversight, rather, I don't think there is a valid reason for it to be pluggable. Any change in the regular expression could expose a security vulnerability. A function to extract items from content could certainly make for a good core function, and there are tickets for that. But allowing this function to be pluggable doesn't help much.

Change History (2)

comment:1 lancewillett14 months ago

Agreed on all points. Once #23618 is closed we can avoid the issue entirely by deleting the entire function from the theme.

comment:2 lancewillett13 months ago

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

Fixed with r23792.

Note: See TracTickets for help on using tickets.