orthoses-paranoia 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 17021bf453e971f9680729d7bc31e518010ef1a63a2f37c892f6503d1261e59d
4
- data.tar.gz: d2ee4b7582c7a6458d2b508890ea69858acf4d58aad3c3e73742c2bf1f28a82d
3
+ metadata.gz: ccba2e944aacb3256d6475ef6bf5ffe0a7753a20c7c3b085d551e07c2a3926a1
4
+ data.tar.gz: 0f06e4ca2ffeab93c977e6b13bb45166144c9342a483e823db9a3a57de6e0c5e
5
5
  SHA512:
6
- metadata.gz: 1bdf31889f848a5546877d53d1e13dbd12eb623b867797a79935ff14ea81c9e75eb62a8f5ed559d3dc86459706c14fea13918c2d1d040205ec6f40eedfd54cef
7
- data.tar.gz: 0c95d6ee077313c43bf88076a716016c1b6d362d268aa6b4cffa96ae12ad46ca996396185a0f379e3df939e921ba7bbc397d7ae0481f783638c191616e39d0dd
6
+ metadata.gz: 4bfc624d2f070ffbb39f9c67c9a28f28d385d177486b22f90404db02d2ce4b52c42a0e632ac94e4e3531039ef5464e8020ed3c34e64c5bba7f1e638e165858bc
7
+ data.tar.gz: aa51ca2be432ada57728a472795222126873345e86f4cf4ac1d012fae85998da0f5b39091b9a1ad79d4af11be50d1462a8cfd43bda7c17f978b8e04c283c1400
data/README.md CHANGED
@@ -9,18 +9,16 @@ User.with_deleted #=> User::ActiveRecord_Relation
9
9
 
10
10
  ## Installation
11
11
 
12
- TODO: Replace `UPDATE_WITH_YOUR_GEM_NAME_IMMEDIATELY_AFTER_RELEASE_TO_RUBYGEMS_ORG` with your gem name right after releasing it to RubyGems.org. Please do not do it earlier due to security reasons. Alternatively, replace this section with instructions to install your gem from git if you don't plan to release to RubyGems.org.
13
-
14
12
  Install the gem and add to the application's Gemfile by executing:
15
13
 
16
14
  ```bash
17
- bundle add UPDATE_WITH_YOUR_GEM_NAME_IMMEDIATELY_AFTER_RELEASE_TO_RUBYGEMS_ORG
15
+ bundle add orthoses-paranoia
18
16
  ```
19
17
 
20
18
  If bundler is not being used to manage dependencies, install the gem by executing:
21
19
 
22
20
  ```bash
23
- gem install UPDATE_WITH_YOUR_GEM_NAME_IMMEDIATELY_AFTER_RELEASE_TO_RUBYGEMS_ORG
21
+ gem install orthoses-paranoia
24
22
  ```
25
23
 
26
24
  ## Usage
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Orthoses
4
4
  class Paranoia
5
- VERSION = "0.1.0"
5
+ VERSION = "0.2.0"
6
6
  end
7
7
  end
@@ -17,7 +17,7 @@ module Orthoses
17
17
 
18
18
  acts_as_paranoid.captures.each do |capture|
19
19
  base_name = Utils.module_name(capture.method.receiver) or next
20
- paranoia_class_methods = "#{base_name}::ParanoiaClassMethods"
20
+ paranoia_class_methods = "#{base_name}::ParanoiaMethods"
21
21
  next if store.key?(paranoia_class_methods)
22
22
 
23
23
  store[paranoia_class_methods].header = "module #{paranoia_class_methods}"
@@ -28,6 +28,8 @@ module Orthoses
28
28
  store[paranoia_class_methods] << "alias without_deleted paranoia_scope"
29
29
 
30
30
  store[base_name] << "extend #{paranoia_class_methods}"
31
+ store["#{base_name}::ActiveRecord_Relation"] << "include #{paranoia_class_methods}"
32
+ store["#{base_name}::ActiveRecord_Associations_CollectionProxy"] << "include #{paranoia_class_methods}"
31
33
  end
32
34
 
33
35
  store
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: orthoses-paranoia
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ksss
8
8
  bindir: exe
9
9
  cert_chain: []
10
- date: 2025-03-08 00:00:00.000000000 Z
10
+ date: 2025-03-13 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: orthoses