Make WordPress Core

Ticket #10706: strict-force-ssl.diff

File strict-force-ssl.diff, 941 bytes (added by nbachiyski, 16 years ago)
  • wp-includes/functions.php

     
    30573057 * @param string|bool $force Optional.
    30583058 * @return bool True if forced, false if not forced.
    30593059 */
    3060 function force_ssl_login($force = '') {
    3061         static $forced;
     3060function force_ssl_login( $force = null ) {
     3061        static $forced = false;
    30623062
    3063         if ( '' != $force ) {
     3063        if ( !is_null( $force ) ) {
    30643064                $old_forced = $forced;
    30653065                $forced = $force;
    30663066                return $old_forced;
     
    30773077 * @param string|bool $force
    30783078 * @return bool True if forced, false if not forced.
    30793079 */
    3080 function force_ssl_admin($force = '') {
    3081         static $forced;
     3080function force_ssl_admin( $force = null ) {
     3081        static $forced = false;
    30823082
    3083         if ( '' != $force ) {
     3083        if ( !is_null( $force ) ) {
    30843084                $old_forced = $forced;
    30853085                $forced = $force;
    30863086                return $old_forced;