Changes between Initial Version and Version 1 of Ticket #29684, comment 38
- Timestamp:
- 09/08/2017 03:44:41 PM (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #29684, comment 38
initial v1 3 3 * Run `get_network()` in the very beginning of the function. If no network found, the ID passed is invalid, so the function should return `0` then regardless of the filter. The main reason for running `get_network()` earlier is so that the `pre_get_main_site_id` is always passed an actual ID and never `null` (this was previously possible). 4 4 * The `Tests_Multisite_Get_Main_Site_ID` class now is properly wrapped in an `is_multisite()` checked and contains a docblock with the respective test groups. 5 6 [attachment:29684.16.diff] is a slightly modified version: The only change is that `get_main_site_id()` uses the `$site_id` property of `WP_Network` if it is set. Not entirely sure if we should do that for the first iteration since it interacts with `WP_Network`, but I like the idea and it would address some of the concerns @spacedmonkey was having.