nexus_cqrs 0.4.8 → 0.4.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5eaaa5907400751d2a1e04da16226885b6945a6d04ec5c10b513cec92e10123a
4
- data.tar.gz: aecdbe537dd07314b8e5d66d4c312a353b2d23fade004412a26998c041ea7af0
3
+ metadata.gz: 6e8ee5ed4253fc4a5aa94759a8f3c367421b0d7be44d6777c90c276787d9ea4b
4
+ data.tar.gz: 76b40be983df9643f0a5f3d3e2840680df819d50833705effeff16742169cb47
5
5
  SHA512:
6
- metadata.gz: cbc0b64117f244c62d96f9fb75c7c030e9d8ab62e4cf206396066dbf7eeb416fda0787c506d567eae31d56d06e135eee1922fbcbc48411b937505fe33d90186f
7
- data.tar.gz: 2c103ccfa697dad306e40eebe48b856bfd7bc2e347ce728bce8c560adc68c2a2c31f007c0c556d637a78daaf967c9f1127c4e196d842ac5ffb3ea3cafd5aa4fb
6
+ metadata.gz: a7adb30cee344cd75643c0a62ccca0731d78e425756a678d079a8e975bf562565f3f1aa10f4a18946117fd2e4bb216ee0b9d5b64c00c756c059c5d9ab4f27457
7
+ data.tar.gz: cec44e682a10b09e837a98a34b05d25b7b63486c775dafafa8f54880d113d63941199d754d0047f9616db037e6d5b1d37c54a9e45193aa7cee793e55e353ef86
data/.rubocop.yml CHANGED
@@ -2,12 +2,14 @@ inherit_gem:
2
2
  rubocop-shopify: rubocop.yml
3
3
 
4
4
  AllCops:
5
+ TargetRubyVersion: 3.2
5
6
  Exclude:
6
7
  - db/schema.rb
7
8
  - db/seeds.rb
8
9
  - db/migrate/*.rb
9
10
  - config/initializers/devise.rb
10
11
  - spec/**/*
12
+ - lib/generators/nexus_cqrs/templates/*
11
13
 
12
14
  Style/Documentation:
13
15
  Enabled: false
data/Gemfile.lock CHANGED
@@ -12,106 +12,108 @@ PATH
12
12
  GEM
13
13
  remote: https://rubygems.org/
14
14
  specs:
15
- actionpack (6.1.4.1)
16
- actionview (= 6.1.4.1)
17
- activesupport (= 6.1.4.1)
18
- rack (~> 2.0, >= 2.0.9)
15
+ actionpack (7.0.4.3)
16
+ actionview (= 7.0.4.3)
17
+ activesupport (= 7.0.4.3)
18
+ rack (~> 2.0, >= 2.2.0)
19
19
  rack-test (>= 0.6.3)
20
20
  rails-dom-testing (~> 2.0)
21
21
  rails-html-sanitizer (~> 1.0, >= 1.2.0)
22
- actionview (6.1.4.1)
23
- activesupport (= 6.1.4.1)
22
+ actionview (7.0.4.3)
23
+ activesupport (= 7.0.4.3)
24
24
  builder (~> 3.1)
25
25
  erubi (~> 1.4)
26
26
  rails-dom-testing (~> 2.0)
27
27
  rails-html-sanitizer (~> 1.1, >= 1.2.0)
28
- activesupport (6.1.4.1)
28
+ activesupport (7.0.4.3)
29
29
  concurrent-ruby (~> 1.0, >= 1.0.2)
30
30
  i18n (>= 1.6, < 2)
31
31
  minitest (>= 5.1)
32
32
  tzinfo (~> 2.0)
33
- zeitwerk (~> 2.3)
34
33
  ast (2.4.2)
35
34
  builder (3.2.4)
36
- concurrent-ruby (1.1.10)
35
+ concurrent-ruby (1.2.2)
37
36
  crass (1.0.6)
38
- diff-lcs (1.4.4)
39
- erubi (1.10.0)
37
+ diff-lcs (1.5.0)
38
+ erubi (1.12.0)
40
39
  generator_spec (0.9.4)
41
40
  activesupport (>= 3.0.0)
42
41
  railties (>= 3.0.0)
43
- i18n (1.10.0)
42
+ i18n (1.12.0)
44
43
  concurrent-ruby (~> 1.0)
45
44
  ibsciss-middleware (0.4.2)
46
- loofah (2.12.0)
45
+ json (2.6.3)
46
+ loofah (2.20.0)
47
47
  crass (~> 1.0.2)
48
48
  nokogiri (>= 1.5.9)
49
49
  method_source (1.0.0)
50
- mini_portile2 (2.6.1)
51
- minitest (5.15.0)
52
- nokogiri (1.12.5)
53
- mini_portile2 (~> 2.6.1)
50
+ mini_portile2 (2.8.1)
51
+ minitest (5.18.0)
52
+ nokogiri (1.14.2)
53
+ mini_portile2 (~> 2.8.0)
54
54
  racc (~> 1.4)
55
- parallel (1.21.0)
56
- parser (3.0.2.0)
55
+ parallel (1.22.1)
56
+ parser (3.2.2.0)
57
57
  ast (~> 2.4.1)
58
- pundit (2.2.0)
58
+ pundit (2.3.0)
59
59
  activesupport (>= 3.0.0)
60
- racc (1.6.0)
61
- rack (2.2.3)
62
- rack-test (1.1.0)
63
- rack (>= 1.0, < 3)
60
+ racc (1.6.2)
61
+ rack (2.2.6.4)
62
+ rack-test (2.1.0)
63
+ rack (>= 1.3)
64
64
  rails-dom-testing (2.0.3)
65
65
  activesupport (>= 4.2.0)
66
66
  nokogiri (>= 1.6)
67
- rails-html-sanitizer (1.4.2)
68
- loofah (~> 2.3)
69
- railties (6.1.4.1)
70
- actionpack (= 6.1.4.1)
71
- activesupport (= 6.1.4.1)
67
+ rails-html-sanitizer (1.5.0)
68
+ loofah (~> 2.19, >= 2.19.1)
69
+ railties (7.0.4.3)
70
+ actionpack (= 7.0.4.3)
71
+ activesupport (= 7.0.4.3)
72
72
  method_source
73
- rake (>= 0.13)
73
+ rake (>= 12.2)
74
74
  thor (~> 1.0)
75
- rainbow (3.0.0)
75
+ zeitwerk (~> 2.5)
76
+ rainbow (3.1.1)
76
77
  rake (13.0.6)
77
- regexp_parser (2.1.1)
78
- request_store (1.5.0)
78
+ regexp_parser (2.7.0)
79
+ request_store (1.5.1)
79
80
  rack (>= 1.4)
80
81
  rexml (3.2.5)
81
- rspec (3.10.0)
82
- rspec-core (~> 3.10.0)
83
- rspec-expectations (~> 3.10.0)
84
- rspec-mocks (~> 3.10.0)
85
- rspec-core (3.10.1)
86
- rspec-support (~> 3.10.0)
87
- rspec-expectations (3.10.1)
82
+ rspec (3.12.0)
83
+ rspec-core (~> 3.12.0)
84
+ rspec-expectations (~> 3.12.0)
85
+ rspec-mocks (~> 3.12.0)
86
+ rspec-core (3.12.1)
87
+ rspec-support (~> 3.12.0)
88
+ rspec-expectations (3.12.2)
88
89
  diff-lcs (>= 1.2.0, < 2.0)
89
- rspec-support (~> 3.10.0)
90
- rspec-mocks (3.10.2)
90
+ rspec-support (~> 3.12.0)
91
+ rspec-mocks (3.12.5)
91
92
  diff-lcs (>= 1.2.0, < 2.0)
92
- rspec-support (~> 3.10.0)
93
- rspec-support (3.10.3)
94
- rubocop (1.22.3)
93
+ rspec-support (~> 3.12.0)
94
+ rspec-support (3.12.0)
95
+ rubocop (1.50.0)
96
+ json (~> 2.3)
95
97
  parallel (~> 1.10)
96
- parser (>= 3.0.0.0)
98
+ parser (>= 3.2.0.0)
97
99
  rainbow (>= 2.2.2, < 4.0)
98
100
  regexp_parser (>= 1.8, < 3.0)
99
- rexml
100
- rubocop-ast (>= 1.12.0, < 2.0)
101
+ rexml (>= 3.2.5, < 4.0)
102
+ rubocop-ast (>= 1.28.0, < 2.0)
101
103
  ruby-progressbar (~> 1.7)
102
- unicode-display_width (>= 1.4.0, < 3.0)
103
- rubocop-ast (1.13.0)
104
- parser (>= 3.0.1.1)
104
+ unicode-display_width (>= 2.4.0, < 3.0)
105
+ rubocop-ast (1.28.0)
106
+ parser (>= 3.2.1.0)
105
107
  rubocop-shopify (1.0.7)
106
108
  rubocop (~> 1.4)
107
- ruby-progressbar (1.11.0)
109
+ ruby-progressbar (1.13.0)
108
110
  strings-case (0.3.0)
109
- thor (1.1.0)
111
+ thor (1.2.1)
110
112
  thread_safe (0.3.6)
111
- tzinfo (2.0.4)
113
+ tzinfo (2.0.6)
112
114
  concurrent-ruby (~> 1.0)
113
- unicode-display_width (2.1.0)
114
- zeitwerk (2.5.4)
115
+ unicode-display_width (2.4.2)
116
+ zeitwerk (2.6.7)
115
117
 
116
118
  PLATFORMS
117
119
  ruby
@@ -23,6 +23,9 @@ module NexusCqrs
23
23
  user = message.metadata[:current_user]
24
24
  global_permissions = message.metadata[:global_permissions]
25
25
 
26
+ # Raise issue if policy class doesn't exist
27
+ raise Pundit::NotAuthorizedError, query: query, record: record if policy_class.nil?
28
+
26
29
  # Instantiate new policy class, with context
27
30
  policy = policy_class.new(UserContext.new(user, global_permissions), record)
28
31
  raise Pundit::NotAuthorizedError, query: query, record: record, policy: policy unless policy.public_send(query)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
  module NexusCqrs
3
- # Leave this as 0.4.8 in order for CI process to replace with the tagged version.
4
- VERSION = '0.4.8'
3
+ # Leave this as 0.4.9 in order for CI process to replace with the tagged version.
4
+ VERSION = '0.4.9'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nexus_cqrs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.8
4
+ version: 0.4.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dean Lovett
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-10-18 00:00:00.000000000 Z
11
+ date: 2023-04-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: generator_spec
@@ -154,7 +154,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
154
154
  - !ruby/object:Gem::Version
155
155
  version: '0'
156
156
  requirements: []
157
- rubygems_version: 3.3.24
157
+ rubygems_version: 3.4.11
158
158
  signing_key:
159
159
  specification_version: 4
160
160
  summary: Core package for the nexus cqrs gem