HornsAndHooves-moribus 0.9.1 → 0.10.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/lib/moribus/aggregated_behavior.rb +3 -3
- data/lib/moribus/version.rb +3 -1
- data/spec/support/moribus_spec_model.rb +2 -3
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 39ad765918ae1ca73efc10e704346476936df1793e19f25089d27910089871d7
|
4
|
+
data.tar.gz: 0b579beea800b1b5987e9b7996137efc9dfa5c3e12f70fb04c53f7a5e113ea84
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bf6c76a8ae0260b424abefe0de61c9b5bb11cfd2b6c00d604db9144bf92b911363f7a5bbaed5f22bd403e218ba9a3db0c92ef1b372430cbdb0f155fba200f9f5
|
7
|
+
data.tar.gz: c54c2c7fd4f356dadb559bb41ac262c00d54f8e4ae5f8999f53be79b0bf6a651f5ea2c797f9dcff2f2d1a149df5ea4494250bf728bd27411910fbf4f049ae9a3
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.
|
1
|
+
2.7.6
|
@@ -26,7 +26,7 @@ module Moribus
|
|
26
26
|
# the lookup succeeds, we don't want the original #save to be executed.
|
27
27
|
# But if +false+ is returned by the callback, it will also be returned
|
28
28
|
# by the #save method, wrongly indicating the result of saving.
|
29
|
-
def save(
|
29
|
+
def save(**)
|
30
30
|
@updated_as_aggregated = false
|
31
31
|
run_callbacks(:save) do
|
32
32
|
return (lookup_self_and_replace or super) if new_record?
|
@@ -47,8 +47,8 @@ module Moribus
|
|
47
47
|
end
|
48
48
|
|
49
49
|
# Bang version of #save.
|
50
|
-
def save!(
|
51
|
-
save(
|
50
|
+
def save!(**kwargs)
|
51
|
+
save(**kwargs) or raise_record_not_saved_error
|
52
52
|
end
|
53
53
|
|
54
54
|
# Raise "record not saved".
|
data/lib/moribus/version.rb
CHANGED
@@ -47,8 +47,7 @@ def MoribusSpecModel(column_definition = {})
|
|
47
47
|
end
|
48
48
|
options[:default] = 0 if name == :lock_version
|
49
49
|
args = [type, name]
|
50
|
-
args
|
51
|
-
t.send(*args)
|
50
|
+
t.send(*args, **options)
|
52
51
|
end
|
53
52
|
end
|
54
53
|
end
|
@@ -56,4 +55,4 @@ def MoribusSpecModel(column_definition = {})
|
|
56
55
|
end
|
57
56
|
end
|
58
57
|
end
|
59
|
-
end
|
58
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: HornsAndHooves-moribus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.10.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- HornsAndHooves
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date:
|
14
|
+
date: 2024-01-09 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: rails
|
@@ -208,7 +208,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
208
208
|
- !ruby/object:Gem::Version
|
209
209
|
version: '0'
|
210
210
|
requirements: []
|
211
|
-
rubygems_version: 3.
|
211
|
+
rubygems_version: 3.1.6
|
212
212
|
signing_key:
|
213
213
|
specification_version: 4
|
214
214
|
summary: Introduces Aggregated and Tracked behavior to ActiveRecord::Base models
|