3 ms·
Very valid point and I've seen this occurrence in other projects as well. I'd also recommend looking into using role based authorization (ACL) by using cancan,
by drewtemp 15y ago
Very valid point and I've seen this occurrence in other projects as well.
I'd also recommend looking into using role based authorization (ACL) by using cancan, acl9, or other gems.
- seivan 15y agoWell yeah, but for most part, just make sure the user is deleting something that belongs to him. No point in introducing CanCan or ACL unless you got some more role action going on. Moderators, Admins etc. Also, by delete. I mean version and hide. Not actually deleting it.