A small gem that helps to delete an ActiveRecord instance or collection with associations (skipping callbacks or validations)
Add this line to your application's Gemfile and then execute
Vandal gem adds 2 methods to
Delete an ActiveRecord instance with associations even if the callbacks return false or rescue error.
class User has_many :followers # Does not even contain dependent: :destroy end User.find_by(id: 1).vandal_destroy
Followers will deleted along with
vandal_destroy for ActiveRecord collection
Bug reports and pull requests are welcome on GitHub at https://github.com/kirillshevch/vandal.
The gem is available as open source under the terms of the MIT License.