Support the ongoing development of Laravel.io →
posted 10 years ago
Eloquent
Last updated 2 years ago.
0

Does the todo with that $id exists, probably it seems like it's deleting it because it never existed.

Last updated 2 years ago.
0

Yeah, it exists. Before deleting I see that record.

Last updated 2 years ago.
0

Maybe just add

if ( ! $todo ) {
    // No record found
}
Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Albert221 albert221 Joined 13 Apr 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.