Make WordPress Core

Opened 9 years ago

Closed 3 years ago

#42091 closed enhancement (maybelater)

Use get_site_by() in get_id_from_blogname()

Reported by: jeremyfelt Owned by: jeremyfelt
Priority: normal Milestone:
Component: Networks and Sites Version:
Severity: normal Keywords: has-unit-tests has-patch
Cc: Focuses: multisite

Description

The introduction of get_site_by() (see #40180) gives us the opportunity to clean up some similar code.

Attachments (2)

42091.diff​ (985 bytes ) - added by jeremyfelt 9 years ago.
42091.2.diff​ (1.3 KB ) - added by jeremyfelt 9 years ago.

Download all attachments as: .zip

Change History (10)

@jeremyfelt
9 years ago

@jeremyfelt
9 years ago

#1 @jeremyfelt
9 years ago

  • Owner set to jeremyfelt
  • Resolution → fixed
  • Status new → closed

In 41743:

Multisite: Use get_site_by() in get_id_from_blogname().

Fixes #42091.

#2 @flixos90
9 years ago

  • Resolution fixed
  • Status closed → reopened

As get_site_by() will be reverted (see https://core.trac.wordpress.org/ticket/40180#comment:36), this needs to be reverted as well. It can be merged back in once get_site_by() is actually ready.

#3 @flixos90
9 years ago

In 41884:

Multisite: Revert [41698] and [41743].

In order for get_site_by() to be truly beneficial, caching in WP_Site_Query needs to be improved to account for common use-cases and have them be invalidated less aggressively.

See #40180, #40228, #42091.

#4 @flixos90
9 years ago

  • Keywords has-patch added; needs-patch removed
  • Milestone 4.9 → 5.0

This ticket was mentioned in ​Slack in #core-multisite by flixos90. ​View the logs.


9 years ago

#6 @flixos90
8 years ago

  • Milestone 5.0 → 5.1

#7 @pento
8 years ago

  • Milestone 5.1 → Future Release

#8 @jeremyfelt
3 years ago

  • Milestone Future Release
  • Resolution → maybelater
  • Status reopened → closed

get_site_by() isn't a function until #40180 happens, so this can be closed as maybelater.

Note: See TracTickets for help on using tickets.