Protect records from being destroyed in a declarative way. Simply add 'protect_if :dont_delete, "Record is marked as not deletable"' to your ActiveRecord model. Your record will no be destroyed and the given message is added to the errors object.
Required Ruby Version
>= 0
Authors
Pascal Zumkehr
Versions
-
0.2.0
-
source
- 0.2.0 source July 11, 2017 (8.5 KB)
-
-
0.1.0
-
source
- 0.1.0 source February 07, 2011 (7 KB)
-