### Eclipse Workspace Patch 1.0
#P wordpress
Index: wp-includes/capabilities.php
===================================================================
--- wp-includes/capabilities.php	(revision 15308)
+++ wp-includes/capabilities.php	(working copy)
@@ -474,20 +474,31 @@
 	 * @return WP_User
 	 */
 	function WP_User( $id, $name = '' ) {
-
-		if ( empty( $id ) && empty( $name ) )
+		 
+		// parse input
+		$id   = null;
+		$name = null;
+		if ( 2 != ( $num = func_num_args() ) && $num != 1 )
 			return;
-
-		if ( ! is_numeric( $id ) ) {
-			$name = $id;
-			$id = 0;
+					 
+		$param = func_get_args();
+		
+		if ( 2 == $num ) {
+			$name  = $param[1];
+		} else {
+			$is_id = is_scalar($param[0]) ? (string)$id === (string)(int)$id : false;							
+			$is_id && $id = $param[0] || $name = $param[0];
 		}
-
-		if ( ! empty( $id ) )
+		
+		// process input
+		if ( isset( $id ) ) {
 			$this->data = get_userdata( $id );
-		else
+		} elseif ( isset( $name ) ) {
 			$this->data = get_userdatabylogin( $name );
-
+		} else {
+			return;
+		}
+		
 		if ( empty( $this->data->ID ) )
 			return;
 
