Skip to content

Conversation

@jeremyfelt
Copy link
Contributor

Addresses #303:

  • Update how a network is defined by assuming only one network exists and is defined in the configuration.
  • Watch for the likely not to happen scenario where a second network is installed.
  • Catch a case where the site_admins network option may not be properly set during installation locally.
  • Allow downloads.wordpress.org URLs to survive the protocol relative filter so that local updates will work nicely.

This takes a slightly different approach from @Ipstenu in #378 as there are quite a few gotchas hanging out there when running this outside of the Vagrant environment and/or when installing and upgrading.

There's probably room for future improvement, especially once the Vagrant box has been updated to use a newer version of WordPress by default. We could then rewrite a bit more and make a few more assumptions about the environment. This should work as a pretty good stop-gap in the meantime.

I've tested:

  • New install of the environment in WordPress 3.8.1
  • Upgrade from WordPress 3.8.1 to 4.3.1
  • New install of the environment in WordPress 4.3

As of WordPress 3.9, `wpmu_current_site()` was deprecated and not
left with a full, working replacement.

We know that this environment relies on a single multisite network
and can populate a network object accordingly. If for some reason
multiple networks are used in the future, check to make sure the
populated site object matches the network as expected.
During initial installation, it's possible for the `site_admins`
meta key to be left blank and for a new meta key/value store to
be created after that one is misread. We should delete this option
during installation before recreating it with the current user
performing the install.
A filter is added to make all URLs protocol relative, but our
handling of these in WordPress core for updates doesn't work. It's
possible this works in future versions of WordPress, but in my
testing while upgrading from 3.8.1 to 4.3.1, things stood still. :)
@jquerybot
Copy link

Thank you for your pull request. It looks like this may be your first contribution to a jQuery Foundation project, if so we need you to sign our Contributor License Agreement (CLA).

📝 Please visit http://contribute.jquery.org/CLA/ to sign.

After you signed, the PR is checked again automatically after a minute. If there's still an issue, please reply here to let us know.


If you've already signed our CLA, it's possible your git author information doesn't match your CLA signature (both your name and email have to match), for more information, check the status of your CLA check.

@gnarf
Copy link
Member

gnarf commented Oct 13, 2015

Just tested, everything looks great - Thanks so much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants