Registry / database / paranoia

paranoia

JSON →
library3.1.0rbrubygemsunverified

A re-implementation of acts_as_paranoid for Rails that soft-deletes records by setting a deleted_at field.

gem install paranoia
INSTALL
IMPORT
SIG · PARANOIA
P
paranoia
databaserubyv3.1.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Paranoia
require 'paranoia'

Soft-delete ActiveRecord models with paranoia.

require 'paranoia' class User < ActiveRecord::Base acts_as_paranoid end user = User.first user.destroy # sets deleted_at, doesn't delete row User.with_deleted.find(user.id) # still accessible
Debug
Known issues
gotchaParanoia overrides destroy and may conflict with other gems that also modify destroy behavior.
fix
Ensure paranoia is loaded after other gems that modify destroy, or use paranoia's callbacks carefully.
affects: >= 3.0.0
Upgrade
Version history
3.1.0latest on RubyGems
Audit
Dependencies

No dependency data recorded yet.

Agent activity
31 hits · last 30 days
node
30
Resources
paranoia — gem install paranoia · libregistry