Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix network creation #184

Open
wants to merge 25 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
12ce2cf
add wp-multi-network-functions
mlwilkerson Oct 25, 2022
04471bf
WIP: working toward a test of adding a network after activating this …
mlwilkerson Oct 25, 2022
d812349
complete a failing test for adding a network after activating this pl…
mlwilkerson Oct 25, 2022
f27c5c6
Fix ReleaseProvider options storage in multisite to use main network
mlwilkerson Oct 25, 2022
c9ad87f
code cleanup and auto-formatting
mlwilkerson Oct 25, 2022
e637cac
add failing tests for multisite upgrade
mlwilkerson Oct 25, 2022
8f4700c
test refactoring
mlwilkerson Oct 25, 2022
2ed559b
add exception for multisite upgrade
mlwilkerson Oct 25, 2022
6cf8697
implement multisite upgrade for moving release metadata network optio…
mlwilkerson Oct 25, 2022
6705c24
when delete_network_option when cleaning up ReleaseProvider
mlwilkerson Oct 25, 2022
15e7027
include network option deletion in the cleanup utility plugin
mlwilkerson Oct 25, 2022
2e05680
bump to verson 4.3.2-1
mlwilkerson Oct 25, 2022
3861bc7
fix and test multisite uninstall
mlwilkerson Oct 26, 2022
7d26a84
WIP: multisite test refactoring
mlwilkerson Oct 26, 2022
0029e3c
fix multisite-upgrade test
mlwilkerson Oct 26, 2022
15572f3
add additional assertion to multisite-activation test
mlwilkerson Oct 26, 2022
e5af8e0
more multisite test refactoring
mlwilkerson Oct 26, 2022
4169edd
test cleanup
mlwilkerson Oct 26, 2022
0e1e7fe
auto-formatting
mlwilkerson Oct 26, 2022
e61cf13
ignoreFile for phpcs
mlwilkerson Oct 26, 2022
bb4f7c9
add missing @throws
mlwilkerson Oct 26, 2022
55c94a7
exclude new multisite tests from non-multisite test config
mlwilkerson Oct 26, 2022
548ea9f
bump tested up to 6.1
mlwilkerson Oct 26, 2022
fa31ce5
use literal ints instead of constants to avoid problems on php 5.6
mlwilkerson Oct 26, 2022
7a1fb00
update test matrix to test with 6.1-RC3
mlwilkerson Oct 26, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
include network option deletion in the cleanup utility plugin
  • Loading branch information
mlwilkerson committed Oct 25, 2022
commit 15e70274f726bd28669a4d7de421c4c9a0202dda
10 changes: 10 additions & 0 deletions integrations/plugins/font-awesome-cleanup/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ function( ) {
cleanup_site();
}
);

foreach ( get_options() as $option ) {
delete_network_option( get_current_network_id(), $option );
}
} else {
cleanup_site();
}
Expand Down Expand Up @@ -204,6 +208,8 @@ function display_cleanup_scope_multisite() {
if ( $is_cleanup_network_active ) {
$network_id = get_current_network_id();

$networks = get_networks();

for_each_blog(
function( $site ) use (&$sites) {
array_push( $sites, $site );
Expand All @@ -212,6 +218,10 @@ function( $site ) use (&$sites) {
?>
<p>Cleaning ALL sites in network with network_id: <?= $network_id ?>.</p>
<p>To clean up only one site, activate this cleanup plugin only on that one site instead of activating it network-wide.</p>
<?php if ( count( $networks ) > 0 ) { ?>
<p>There are <?php echo count( $networks ) - 1 ?> other networks that will not be affected by this cleanup.</p>
<p>To clean up multiple <em>networks</em>, network activate this cleanup plugin for each network, and run this cleanup for each network.</p>
<?php } ?>
<?php
} else {
array_push( $sites, get_site() );
Expand Down