Laravel 5.4, php 5.6
try to updateOrCreate password reset token her is my attempt.
$passwordReset = ( new PasswordReset )->updateOrCreate(
['email' => $user->email],
[
'email' => $user->email,
'token' => str_random(60)
]
);
create working fine if the user reset his password for the first time, but when update I got this QueryException
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'id' in 'where clause' (SQL: update
password_resetssettoken= 8ALMd5schQR9KNQ5kIt89bwr5lu5mb5G1DpYLttkizN6Z5ZxCcyhYaBp0X97 whereidis null)
email- Yousef Altaf