activerecord-pg-extensions 0.5.0 → 0.5.2
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 76b26256a900d896712a2a43efa814c763713055ebdd211b297e03d7c692804b
|
4
|
+
data.tar.gz: 041a0b3f8c943c47133b45d837128ccd5ba59f7329ce53ca92effbfee85d9f63
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2fafc2346380c64d7a324efee4169912fa87cf088142007d5fb4d13ea2a7f783d6374473a3a51710685204e00e4dde7e4ec895e6bd1daab869087dd8fa89c2a6
|
7
|
+
data.tar.gz: c984f81a6faccbf6d8634051703647816811b6c8fb4aa827c2a70f05964e6583f8a2abbf69d5f083af4e9eee5cd2c22a4e898a43613c36e99263f39b809e7154
|
@@ -90,14 +90,16 @@ module ActiveRecord
|
|
90
90
|
end
|
91
91
|
|
92
92
|
def add_check_constraint(table_name, expression, if_not_exists: false, **options)
|
93
|
-
|
93
|
+
options = check_constraint_options(table_name, expression, options)
|
94
|
+
return if if_not_exists && check_constraint_for(table_name, **options)
|
94
95
|
|
95
96
|
super
|
96
97
|
end
|
97
98
|
|
98
99
|
if ActiveRecord.version < Gem::Version.new("7.1")
|
99
|
-
def remove_check_constraint(table_name, expression = nil, **options)
|
100
|
-
|
100
|
+
def remove_check_constraint(table_name, expression = nil, if_exists: false, **options)
|
101
|
+
options = check_constraint_options(table_name, expression, options)
|
102
|
+
return if if_exists && !check_constraint_for(table_name, **options)
|
101
103
|
|
102
104
|
super
|
103
105
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord-pg-extensions
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cody Cutrer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-09-
|
11
|
+
date: 2023-09-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|