diff --git a/init.php b/init.php index 8965f6a..dda0763 100644 --- a/init.php +++ b/init.php @@ -349,7 +349,7 @@ public function edit_user_profile_update( $user_id ) { if ( ! function_exists( 'wp_handle_upload' ) ) require_once ABSPATH . 'wp-admin/includes/file.php'; - $this->avatar_delete( $this->user_id_being_edited ); + $this->avatar_delete( $user_id ); // Need to be more secure since low privelege users can upload if ( strstr( $_FILES['basic-user-avatar']['name'], '.php' ) )