yt-core 0.1.1 → 0.1.2

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
  SHA1:
3
- metadata.gz: 41f3f21221d78ac0ff0345bc8576c6536d8b1afa
4
- data.tar.gz: d889a7d0f70f476ad1367430e9c390eecf15e261
3
+ metadata.gz: 2faf158ad48511fe585519deb4cd053f41bd2ffe
4
+ data.tar.gz: 3bb7780ffa69dedefc4094be10a43af205c868b8
5
5
  SHA512:
6
- metadata.gz: 23fac23d6a0712fe9867bd24f177e78925fe2c9c55fe8b66a14973c69b0f72d6d60e4fad9208b98182f1bdf4b1f69ae08136f07aa1293619f0cb70c92bd4320f
7
- data.tar.gz: 1cfd65c11a2ccbf174a56a12a4ce5a1bbc8d201ed669fab67042412e11cfa0ba237b8c44b89989d47aafdf802f3804274b70f5a403729f1f9a9ebbbb32fd2854
6
+ metadata.gz: f3445d6fa3b8836a51dfb02a25399780d58e705101c609a07be0d4fa94b9be0acbef06b320af917cc69d42dc8224275217da5700643f3b6b0c66d9f2e0077e4c
7
+ data.tar.gz: 99bb22df52a1a9895f40b6e52b8f4ae956b0bf556887acbbb42e4324cdf7487351db7ecb177e16b40564d7293080da1e5d27b6585160e6bafa2cfcf3f45d7907
@@ -6,6 +6,10 @@ For more information about changelogs, check
6
6
  [Keep a Changelog](http://keepachangelog.com) and
7
7
  [Vandamme](http://tech-angels.github.io/vandamme).
8
8
 
9
+ ## 0.1.2 - 2017-04-06
10
+
11
+ * [BUGFIX] Fix cases like `channel.select(:snippet).view_count` where attribute does not belong to any selected part.
12
+
9
13
  ## 0.1.1 - 2017-04-04
10
14
 
11
15
  * [ENHANCEMENT] Add :defaults to `has_attribute`
@@ -3,6 +3,6 @@ module Yt
3
3
  module Core
4
4
  # @return [String] the SemVer-compatible gem version.
5
5
  # @see http://semver.org
6
- VERSION = '0.1.1'
6
+ VERSION = '0.1.2'
7
7
  end
8
8
  end
@@ -6,7 +6,7 @@ module Yt
6
6
  # @option data [String] :id The unique ID of a YouTube resource.
7
7
  def initialize(data = {})
8
8
  @data = data
9
- @selected_data_parts = nil
9
+ @selected_data_parts = []
10
10
  end
11
11
 
12
12
  # @return [String] the resource’s unique ID.
@@ -65,7 +65,7 @@ module Yt
65
65
  fetch resources_path, resource_params(options)
66
66
  end
67
67
 
68
- parts = @selected_data_parts || [required_part]
68
+ parts = (@selected_data_parts + [required_part]).uniq
69
69
  if (resource = resources.select(*parts).first)
70
70
  parts.each{|part| @data[part] = resource.data[part]}
71
71
  @data[required_part]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yt-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Claudio Baccigalupo
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-04-04 00:00:00.000000000 Z
11
+ date: 2017-04-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: yt-support