Laravel Prefer Orfail Fetch

Use when fetching one Eloquent record that must exist: prefer findOrFail/firstOrFail over a fetch plus a null check that aborts 404.

techmefr Updated

File contents

techmefr/mentis commit bba0e4ffb0

Frequently asked questions

npx get-skill add techmefr/laravel-prefer-orfail-fetch