wcc-media-client 0.7.5 → 0.7.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/lib/wcc/media/active_record_shim.rb +2 -2
- data/lib/wcc/media/client.rb +2 -1
- data/lib/wcc/media/message.rb +5 -2
- data/lib/wcc/media/version.rb +1 -1
- 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: 13811fc5f388b8a84cbfca06f1f96dba8b022b6a5369b7657760251797b0e606
|
4
|
+
data.tar.gz: 5a4d59ba9f640ab75b45d3ece1b1d726941cae5d238cd9353c2bad7094c55038
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ba369d26bbae429ffec8bb50bd638205b5b36ab7adfff616e80fdb46549bb940a6ab85e067896faed8d00925246ad0ba265b0f443fea2fb437f1f21b31a41c51
|
7
|
+
data.tar.gz: 7c81fc559b666d334aa747307dbaeb39ce45e6782d16e50cbc92ec7f1177d70001936c4383fc5475de07a33904ea175f7f56bcf677c4398b285b4fd159dacdc4
|
data/Gemfile
CHANGED
@@ -25,7 +25,7 @@ group :development, :test do
|
|
25
25
|
gem 'simplecov', '~> 0.21.2', require: false
|
26
26
|
gem 'simplecov-cobertura', '~> 1.4'
|
27
27
|
gem 'sprockets', '< 4.0'
|
28
|
-
gem 'sqlite3', '
|
28
|
+
gem 'sqlite3', '>= 1.4'
|
29
29
|
gem 'typhoeus', '~> 1.3'
|
30
30
|
gem 'webmock', '~> 3.0'
|
31
31
|
end
|
@@ -41,7 +41,7 @@ module WCC::Media::ActiveRecordShim
|
|
41
41
|
def find_by(**filters)
|
42
42
|
raise ArgumentError, 'You must provide at least one filter' if filters.empty?
|
43
43
|
|
44
|
-
find_all(filters).first
|
44
|
+
find_all(**filters).first
|
45
45
|
end
|
46
46
|
|
47
47
|
def model_name
|
@@ -64,7 +64,7 @@ module WCC::Media::ActiveRecordShim
|
|
64
64
|
offset: options.delete(:start) || 0
|
65
65
|
}
|
66
66
|
|
67
|
-
find_all(filter).each_slice(batch_size, &block)
|
67
|
+
find_all(**filter).each_slice(batch_size, &block)
|
68
68
|
end
|
69
69
|
|
70
70
|
def where(**conditions)
|
data/lib/wcc/media/client.rb
CHANGED
@@ -1,5 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require 'ostruct'
|
3
4
|
require 'wcc/api/rest_client'
|
4
5
|
require_relative 'message'
|
5
6
|
require_relative 'series'
|
@@ -53,7 +54,7 @@ module WCC
|
|
53
54
|
super(**options)
|
54
55
|
|
55
56
|
RESOURCES.each do |(endpoint, model)|
|
56
|
-
instance_variable_set("@#{endpoint}", Resource.new(self, model, @options))
|
57
|
+
instance_variable_set(:"@#{endpoint}", Resource.new(self, model, @options))
|
57
58
|
end
|
58
59
|
end
|
59
60
|
|
data/lib/wcc/media/message.rb
CHANGED
@@ -33,6 +33,9 @@ class WCC::Media::Message < WCC::Media::Base
|
|
33
33
|
topics
|
34
34
|
hide_from_internal_search
|
35
35
|
archived
|
36
|
+
episode_number
|
37
|
+
season_number
|
38
|
+
episode_type
|
36
39
|
].each do |att|
|
37
40
|
define_method att do
|
38
41
|
raw[att]
|
@@ -40,11 +43,11 @@ class WCC::Media::Message < WCC::Media::Base
|
|
40
43
|
end
|
41
44
|
|
42
45
|
def hide_from_internal_search
|
43
|
-
raw
|
46
|
+
raw.dig('flags', 'hide_from_internal_search') || false
|
44
47
|
end
|
45
48
|
|
46
49
|
def archived?
|
47
|
-
raw
|
50
|
+
raw.dig('flags', 'archived') || false
|
48
51
|
end
|
49
52
|
|
50
53
|
def speakers
|
data/lib/wcc/media/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wcc-media-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Watermark Dev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-05-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: wcc-api
|
@@ -72,7 +72,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
72
72
|
- !ruby/object:Gem::Version
|
73
73
|
version: '0'
|
74
74
|
requirements: []
|
75
|
-
rubygems_version: 3.
|
75
|
+
rubygems_version: 3.4.19
|
76
76
|
signing_key:
|
77
77
|
specification_version: 4
|
78
78
|
summary: ''
|