rails_event_store_active_record 2.5.0 → 2.6.0

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: 1b8d45f8db63265e2f7ff910fcc7023e9ee09181f4d719c6414144e7b3d2aefe
4
- data.tar.gz: d79d9363529face6e861815bf8d9bedf77b25112272ad18d1304b7daf00b236f
3
+ metadata.gz: 1445359a7bc2b8138812009c8d556e9a6deae03871ac6e7119f2bd987d67f993
4
+ data.tar.gz: 8252c208d67c7ede155d5b26590bff5bc66435b238412f8e64451f331050f4dc
5
5
  SHA512:
6
- metadata.gz: 8a38f1a8179ad2ad55d9021d1a9ce70e7a2594f06bf8c9152aca2572df58718bd7a6f849bae3214b29b004b9564d977b425064975168522c9f096829da566589
7
- data.tar.gz: 733045800282094ddc1d4ebb0f3a8c3a4987a77201d11d670d665fde80622827111b625dbd2bc72c9359fa15496e629690476b4a173a9aa0cc3eae04bb17846b
6
+ metadata.gz: 8e5f036edb8a06087486c6daf13ddb8ce9ebfd80faffd49ee00aeae030438f6c40082f094bed22ba6b03c4a1a9369e236703b0e7406dfe1b8b841ae72a712b11
7
+ data.tar.gz: 403c082973e88aa2a2dc87fe5ea1c2c1b4e9f8c6b622352f79d0fa80d3c7e3ff280f4d5ea9579cf31fec41a5d79b4540048a989a4a114c0e66ec51e4ec7f4262
@@ -7,10 +7,12 @@ module RailsEventStoreActiveRecord
7
7
  self.primary_key = :id
8
8
  self.table_name = "event_store_events"
9
9
  end
10
+ private_constant :Event
10
11
 
11
12
  class EventInStream < ::ActiveRecord::Base
12
13
  self.primary_key = :id
13
14
  self.table_name = "event_store_events_in_streams"
14
15
  belongs_to :event, primary_key: :event_id
15
16
  end
17
+ private_constant :EventInStream
16
18
  end
@@ -27,6 +27,8 @@ module RailsEventStoreActiveRecord
27
27
  end
28
28
 
29
29
  def link_to_stream(event_ids, stream, expected_version)
30
+ return if event_ids.empty?
31
+
30
32
  (event_ids - @event_klass.where(event_id: event_ids).pluck(:event_id)).each do |id|
31
33
  raise RubyEventStore::EventNotFound.new(id)
32
34
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module RailsEventStoreActiveRecord
4
- VERSION = "2.5.0"
4
+ VERSION = "2.6.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_event_store_active_record
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.5.0
4
+ version: 2.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arkency
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-06-22 00:00:00.000000000 Z
11
+ date: 2022-11-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ruby_event_store
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 2.5.0
19
+ version: 2.6.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 2.5.0
26
+ version: 2.6.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: activerecord
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -87,7 +87,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
87
87
  - !ruby/object:Gem::Version
88
88
  version: '0'
89
89
  requirements: []
90
- rubygems_version: 3.3.11
90
+ rubygems_version: 3.3.26
91
91
  signing_key:
92
92
  specification_version: 4
93
93
  summary: Persistent event repository implementation for RubyEventStore based on ActiveRecord