Fix issue with being unable to save pirep edits (#1116)

Fixes issue being unable to save pirep edits from the admin section due to incorrect variable being used
pull/1117/head
Andrew Roberts 4 years ago committed by GitHub
parent 50e8f2e52b
commit 3f84f84309
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -15,7 +15,7 @@ class UpdatePirepRequest extends FormRequest
*/
public function authorize(): bool
{
$pirep = Pirep::findOrFail($this->route('id'), ['user_id']);
$pirep = Pirep::findOrFail($this->route('pirep'), ['user_id']);
return $pirep->user_id === Auth::id();
}

Loading…
Cancel
Save