WordPress.org

Make WordPress Core

Opened 10 months ago

Last modified 3 months ago

#44838 reviewing enhancement

Self_Link Should Have Echo Option

Reported by: dshanske Owned by: SergeyBiryukov
Milestone: 5.3 Priority: normal
Severity: normal Version:
Component: Feeds Keywords: good-first-bug has-patch needs-refresh
Focuses: Cc:

Description

There is no get_self_link, so either one should be created or there should be an echo=true argument to address

Attachments (3)

44838.diff (1001 bytes) - added by jojotjebaby 10 months ago.
44838.1.diff (19.2 KB) - added by mobeen-abdullah 10 months ago.
First patch as a new contributor :)
44838.2.diff (1.2 KB) - added by jojotjebaby 10 months ago.
Changed the patch to add a new function get_self_link that is called and echoed by self_link

Download all attachments as: .zip

Change History (19)

#1 @dshanske
10 months ago

  • Keywords needs-patch good-first-bug added

#2 @stevenkword
10 months ago

Makes sense to me.

This ticket was mentioned in Slack in #core by jojotjebaby. View the logs.


10 months ago

@jojotjebaby
10 months ago

#4 @jojotjebaby
10 months ago

  • Version set to trunk

I just attached my patch. I went with the option to add the $echo = true option to the function.

This is my first contribution so some feedback would be welcome :)

This ticket was mentioned in Slack in #core by jojotjebaby. View the logs.


10 months ago

@mobeen-abdullah
10 months ago

First patch as a new contributor :)

#6 follow-up: @dshanske
10 months ago

@mobeen-abdullah Yours is not a diff.

@jojotjebaby Yours is implemented correctly except for not noting the new variable is since 4.9.9 or such...

But, in thinking about this after my initial comment, self_link is useful beyond RSS, which means adding get_self_link without the esc_url makes sense, as only in the original intent of exporting for RSS feeds should you need to escape, and adding two variables to change whether it escapes or not doesn't make sense, so the get function is the better move.

So, self_link would just call get_self_link and echo it with esc_url.

#7 in reply to: ↑ 6 @jojotjebaby
10 months ago

@dshanske , ok I will implement it with the new function and add the patch on here.

@jojotjebaby
10 months ago

Changed the patch to add a new function get_self_link that is called and echoed by self_link

#8 @jojotjebaby
10 months ago

  • Keywords has-patch added; needs-patch removed

#9 @dshanske
10 months ago

  • Milestone changed from Awaiting Review to 4.9.9

#10 @SergeyBiryukov
10 months ago

  • Owner set to SergeyBiryukov
  • Status changed from new to reviewing

#11 @pento
9 months ago

  • Milestone changed from 4.9.9 to 5.0.1

#12 @pento
7 months ago

  • Milestone changed from 5.0.1 to 5.0.2

#13 @pento
6 months ago

  • Milestone changed from 5.0.2 to 5.0.3

#14 @audrasjb
6 months ago

  • Keywords needs-refresh added
  • Milestone changed from 5.0.3 to 5.1

Hi,

5.0.3 is going to be released in a couple of weeks. We are currently sorting the remaining tickets in the milestone. It doesn't appear that ticket can be handled in the next couple of weeks (it will both needs a refresh and a formal review). Let's address it in 5.1 which is coming in February. Feel free to change/ask to change the milestone if you think the issue can be quickly resolved.

#15 @pento
6 months ago

  • Milestone changed from 5.1 to 5.2
  • Version trunk deleted

#16 @desrosj
3 months ago

  • Milestone changed from 5.2 to 5.3

This ticket has not received any attention during the 5.2 cycle. With beta 1 tomorrow, going to punt this to 5.3.

Note: See TracTickets for help on using tickets.