mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 14:20:15 +00:00
Revert [34778], continue using _site_option() for the current network.
The `_network_option()` parameter order will be changing to accept `$network_id` first. The `_site_option()` functions will remain in use throughout core as our way of retrieving a network option for the current network. See #28290. git-svn-id: https://develop.svn.wordpress.org/trunk@34912 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1961,19 +1961,19 @@ function wp_salt( $scheme = 'auth' ) {
|
||||
if ( defined( $const ) && constant( $const ) && empty( $duplicated_keys[ constant( $const ) ] ) ) {
|
||||
$values[ $type ] = constant( $const );
|
||||
} elseif ( ! $values[ $type ] ) {
|
||||
$values[ $type ] = get_network_option( "{$scheme}_{$type}" );
|
||||
$values[ $type ] = get_site_option( "{$scheme}_{$type}" );
|
||||
if ( ! $values[ $type ] ) {
|
||||
$values[ $type ] = wp_generate_password( 64, true, true );
|
||||
update_network_option( "{$scheme}_{$type}", $values[ $type ] );
|
||||
update_site_option( "{$scheme}_{$type}", $values[ $type ] );
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if ( ! $values['key'] ) {
|
||||
$values['key'] = get_network_option( 'secret_key' );
|
||||
$values['key'] = get_site_option( 'secret_key' );
|
||||
if ( ! $values['key'] ) {
|
||||
$values['key'] = wp_generate_password( 64, true, true );
|
||||
update_network_option( 'secret_key', $values['key'] );
|
||||
update_site_option( 'secret_key', $values['key'] );
|
||||
}
|
||||
}
|
||||
$values['salt'] = hash_hmac( 'md5', $scheme, $values['key'] );
|
||||
|
||||
Reference in New Issue
Block a user