Cannot access offset of type string on string in user-edit.php on line 552
-
Using latest wordpress version and getting
Uncaught TypeError: Cannot access offset of type string on string in /home/duducloud/webapps/abctesttest_shop/wp-admin/user-edit.php:552 Stack trace: #0 /home/duducloud/webapps/abctesttest_shop/wp-admin/profile.php(18): require_once() #1 {main} thrown in /home/duducloud/webapps/abctesttest_shop/wp-admin/user-edit.php on line 552
Deactivated all plugins and used default wp theme – still seeing the error.
Edited the mentioned file – user-edit.php and
replaced
if ( $new_email && $new_email[‘newemail’] !== $current_user->user_email && $profile_user->ID === $current_user->ID ) :
with
if ( is_array( $new_email ) && isset( $new_email[‘newemail’] ) && $new_email[‘newemail’] !== $current_user->user_email && $profile_user->ID === $current_user->ID ) :
which fixed the issue.
Can you pls let me know if it is a core wp issue. Im stuck atm. thx
- You must be logged in to reply to this topic.