Make WordPress Core

Ticket #29191: 29191.diff

File 29191.diff, 1.0 KB (added by imath, 11 years ago)
  • src/wp-activate.php

    diff --git src/wp-activate.php src/wp-activate.php
    index 22d69ac..0f6fc35 100644
    get_header(); 
    105105                            echo '<p>'.$result->get_error_message().'</p>';
    106106                        }
    107107                } else {
    108                         $url = get_blogaddress_by_id( (int) $result['blog_id'] );
    109                         $user = get_userdata( (int) $result['user_id'] );
     108                        $r = wp_parse_args( $result, array(
     109                                'blog_id'  => 0,
     110                                'user_id'  => 0,
     111                                'password' => ''
     112                        ) );
     113                        $url = get_blogaddress_by_id( (int) $r['blog_id'] );
     114                        $user = get_userdata( (int) $r['user_id'] );
    110115                        ?>
    111116                        <h2><?php _e('Your account is now active!'); ?></h2>
    112117
    113118                        <div id="signup-welcome">
    114119                                <p><span class="h3"><?php _e('Username:'); ?></span> <?php echo $user->user_login ?></p>
    115                                 <p><span class="h3"><?php _e('Password:'); ?></span> <?php echo $result['password']; ?></p>
     120                                <p><span class="h3"><?php _e('Password:'); ?></span> <?php echo $r['password']; ?></p>
    116121                        </div>
    117122
    118123                        <?php if ( $url != network_home_url('', 'http') ) : ?>