Make WordPress Core

Opened 2 weeks ago

Closed 10 days ago

#62849 closed defect (bug) (fixed)

Rename the "setted_transient" action to "set_transient".

Reported by: peterwilsoncc's profile peterwilsoncc Owned by: sukhendu2002's profile sukhendu2002
Milestone: 6.8 Priority: normal
Severity: normal Version:
Component: Options, Meta APIs Keywords: good-first-bug has-patch
Focuses: Cc:

Description (last modified by peterwilsoncc)

To quote the Merriam-Webster dictionary's page for the definition for setted:

The word you've entered isn't in the dictionary.

The correct work in the context of the action is "set", so I propose renaming the action to correct the misspelling.

This will also introduce consistency with the action name set_transient_{$transient}.

The incorrectly spelt action is used in some popular plugins, the two highest installations with 200K+ active installs, so that may be a blocker due to the amount of log entries it will create. It will not be a back-compat break as it would be covered by a do_action_deprecated() call.


Edit: setted_site_transient ought to be renamed too as part of this, see comment #3 -- @peterwilsoncc

Change History (7)

#1 @swissspidy
2 weeks ago

  • Keywords needs-patch good-first-bug added

This ticket was mentioned in PR #8185 on WordPress/wordpress-develop by @sukhendu2002.


2 weeks ago
#2

  • Keywords has-patch added; needs-patch removed

#3 follow-up: @peterwilsoncc
11 days ago

  • Milestone changed from Awaiting Review to 6.8
  • Owner set to sukhendu2002
  • Status changed from new to assigned

It was pointed out to me (props @johnbillion) that site transients also contain a miss-spelling, setted_site_transient -- that action should be renamed too.

@sukhendu2002, are you able to push a commit to your PR renaming that too?

I've put this ticket on the 6.8 milestone for consideration.

#4 in reply to: ↑ 3 @sukhendu2002
11 days ago

Replying to peterwilsoncc:

It was pointed out to me (props @johnbillion) that site transients also contain a miss-spelling, setted_site_transient -- that action should be renamed too.

@sukhendu2002, are you able to push a commit to your PR renaming that too?

I've put this ticket on the 6.8 milestone for consideration.

Thanks for pointing that out! I've added a commit to rename setted_site_transient as well.

#5 @peterwilsoncc
10 days ago

  • Description modified (diff)

#6 @peterwilsoncc
10 days ago

  • Description modified (diff)

#7 @peterwilsoncc
10 days ago

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

In 59735:

Options/Meta APIs: Rename setted_(site_)_transient to set_....

Deprecate the actions setted_transient and setted_site_transient in favour of set_transient and set_site_transient respectively.

This serves two purposes, the name is consistent with the transient specific actions set_(site_)_transient_{$transient}, and to make the names grammatically correct.

Props sukhendu2002, swissspidy, johnbillion, peterwilsoncc.
Fixes #62849.

Note: See TracTickets for help on using tickets.