You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Adding .unscoped here makes senses. Or, probably, add an option to reload without taking default scopes into account: record.reload_log_date(unscoped: true)
Tell us about your environment
**Ruby Version:3.0.5
**Rails Version:7.0.4
**PostgreSQL Version:13.9
**Logidze Version:1.2.3
What did you do?
Using
logidze
andacts_as_paranoid
in one project. When record is marked as deleted withacts_as_paranoid
, and I load it like so:obj = SomeObject.with_deleted.find(some_id)
and then execute:
obj.reload_log_data
What did you expect to happen?
log_data
gets loadedWhat actually happened?
The query is affected by
acts_as_paranoid
and addsWHERE "some_objects"."deleted_at" IS NULL
- resulting inlog_data
being null.Not sure how to work-around it, or which gem should actually fix it.
The text was updated successfully, but these errors were encountered: