diff --git wp-comments-post.php wp-comments-post.php
index 9c17a35..4516258 100644
--- wp-comments-post.php
+++ wp-comments-post.php
@@ -73,7 +73,7 @@ if ( $user->ID ) {
 
 $comment_type = '';
 
-if ( get_option('require_name_email') && !$user->ID ) {
+if ( get_option('require_name_email') && ! is_user_logged_in() ) {
 	if ( 6 > strlen($comment_author_email) || '' == $comment_author )
 		wp_die( __('Error: please fill the required fields (name, email).') );
 	elseif ( !is_email($comment_author_email))
@@ -90,7 +90,7 @@ $commentdata = compact('comment_post_ID', 'comment_author', 'comment_author_emai
 $comment_id = wp_new_comment( $commentdata );
 
 $comment = get_comment($comment_id);
-if ( !$user->ID ) {
+if ( ! is_user_logged_in() ) {
 	$comment_cookie_lifetime = apply_filters('comment_cookie_lifetime', 30000000);
 	setcookie('comment_author_' . COOKIEHASH, $comment->comment_author, time() + $comment_cookie_lifetime, COOKIEPATH, COOKIE_DOMAIN);
 	setcookie('comment_author_email_' . COOKIEHASH, $comment->comment_author_email, time() + $comment_cookie_lifetime, COOKIEPATH, COOKIE_DOMAIN);
diff --git wp-includes/comment-template.php wp-includes/comment-template.php
index d00c659..31e2ce7 100644
--- wp-includes/comment-template.php
+++ wp-includes/comment-template.php
@@ -1034,8 +1034,6 @@ function comments_popup_link( $zero = false, $one = false, $more = false, $css_c
  * @return string|bool|null Link to show comment form, if successful. False, if comments are closed.
  */
 function get_comment_reply_link($args = array(), $comment = null, $post = null) {
-	global $user_ID;
-
 	$defaults = array('add_below' => 'comment', 'respond_id' => 'respond', 'reply_text' => __('Reply'),
 		'login_text' => __('Log in to Reply'), 'depth' => 0, 'before' => '', 'after' => '');
 
@@ -1056,7 +1054,7 @@ function get_comment_reply_link($args = array(), $comment = null, $post = null)
 
 	$link = '';
 
-	if ( get_option('comment_registration') && !$user_ID )
+	if ( get_option('comment_registration') && ! is_user_logged_in() )
 		$link = '<a rel="nofollow" class="comment-reply-login" href="' . esc_url( wp_login_url( get_permalink() ) ) . '">' . $login_text . '</a>';
 	else
 		$link = "<a class='comment-reply-link' href='" . esc_url( add_query_arg( 'replytocom', $comment->comment_ID ) ) . "#" . $respond_id . "' onclick='return addComment.moveForm(\"$add_below-$comment->comment_ID\", \"$comment->comment_ID\", \"$respond_id\", \"$post->ID\")'>$reply_text</a>";
@@ -1095,8 +1093,6 @@ function comment_reply_link($args = array(), $comment = null, $post = null) {
  * @return string|bool|null Link to show comment form, if successful. False, if comments are closed.
  */
 function get_post_reply_link($args = array(), $post = null) {
-	global $user_ID;
-
 	$defaults = array('add_below' => 'post', 'respond_id' => 'respond', 'reply_text' => __('Leave a Comment'),
 		'login_text' => __('Log in to leave a Comment'), 'before' => '', 'after' => '');
 
@@ -1107,7 +1103,7 @@ function get_post_reply_link($args = array(), $post = null) {
 	if ( !comments_open($post->ID) )
 		return false;
 
-	if ( get_option('comment_registration') && !$user_ID ) {
+	if ( get_option('comment_registration') && ! is_user_logged_in() ) {
 		$link = '<a rel="nofollow" href="' . wp_login_url( get_permalink() ) . '">' . $login_text . '</a>';
 	} else {
 		$link = "<a rel='nofollow' class='comment-reply-link' href='" . get_permalink($post->ID) . "#$respond_id' onclick='return addComment.moveForm(\"$add_below-$post->ID\", \"0\", \"$respond_id\", \"$post->ID\")'>$reply_text</a>";
diff --git wp-includes/ms-deprecated.php wp-includes/ms-deprecated.php
index a7f7eb2..c307f04 100644
--- wp-includes/ms-deprecated.php
+++ wp-includes/ms-deprecated.php
@@ -44,8 +44,7 @@ function is_site_admin( $user_login = '' ) {
 	_deprecated_function( __FUNCTION__, '3.0', 'is_super_admin()' );
 
 	if ( empty( $user_login ) ) {
-		$user_id = get_current_user_id();
-		if ( !$user_id )
+		if ( ! is_user_logged_in() )
 			return false;
 	} else {
 		$user = get_user_by( 'login', $user_login );
