This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Fix a race condition in alloptions caching | |
* | |
* @link https://core.trac.wordpress.org/ticket/31245 | |
* @link https://github.com/Automattic/vip-go-mu-plugins-built/blob/master/misc.php#L75 | |
*/ | |
function _knife_maybe_clear_alloptions_cache( $option ) { | |
if ( ! wp_installing() ) { | |
$alloptions = wp_load_alloptions(); //alloptions should be cached at this point |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
limit_req_zone $binary_remote_addr zone=login:10m rate=3r/m; | |
set $secret_admin "948b5fee-a224-4c7d-bbf4-d4231e85be2c"; | |
location ~* ^/hidden-wp-admin/?$ { | |
add_header Set-Cookie "secret_admin=$secret_admin; Path=/"; | |
return 302 /wp-admin/; | |
} | |
location = /wp-login.php { |
OlderNewer