m3u8 0.5.2 → 0.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e5c073951f7f46336970cc6f1e16c38e89f4705d
4
- data.tar.gz: af7de6933beb9ae49f2a88f4aad6124aafb4c88f
3
+ metadata.gz: f41fb7682951bc08373079dfee9f08b6989b350a
4
+ data.tar.gz: bd20a5df1f8db01cab94eccc1be9b451071712a3
5
5
  SHA512:
6
- metadata.gz: f5440e1466f6f24dcf44f39e03ef44034b7aca088a81e5363e3778472b5d1d3c901d8c6cc40a78efdc9ce8c5354a789843d998606d661d3cf9f478798fd639f2
7
- data.tar.gz: c02a202da39fd3d5611dcb3a059e56d2f64f0b036622f364fc21d27cfbf55d673fc8fc4c7ab967f4363024de3267b34f1cb916822468ff1e662e78ae8d649237
6
+ metadata.gz: fe388514a463c631a000fff5ce7cffaa0b93475ec2f3c0911701b049bf5cd97383a19ffc69e5e37f4943320652582d9e26de625a8b888d8dd6a57e33e7c8f65c
7
+ data.tar.gz: d68bafed0338082337721ce185286577c1079b57eb99eefa9049b4775e4bca46c38f5bbe2993aa6dd69c7d0a27050194f5971e0e6ce9b74bbd0b79c48bc40954
@@ -1,3 +1,5 @@
1
+ ### 0.5.3 (2/24/2015) - [stan3](https://github.com/stan3) fixed issue recently introduced in Reader where EXT-X-STREAM-INF missing resolution would break parsing.
2
+
1
3
  #### 0.5.2 (2/18/2015) - Fix issue where PlaylistItem.average_bandwidth would default to 0 instead of nil when not present in m3u8 being parsed.
2
4
 
3
5
  #### 0.5.1 (2/16/2015) - [takashisite](https://github.com/takashisite) added support for [EXT-X-DISCONTINUITY](https://tools.ietf.org/html/draft-pantos-http-live-streaming-14#section-4.3.2.3). Added support for [EXT-X-KEY](https://tools.ietf.org/html/draft-pantos-http-live-streaming-14#section-4.3.2.4) (keys for encrypted segments).
@@ -57,7 +57,9 @@ module M3u8
57
57
 
58
58
  def match_tag(line)
59
59
  tag = @tags.select { |key| line.start_with? key }
60
- tag.values.first.call line unless tag.empty?
60
+ return unless tag.values.first
61
+ tag.values.first.call line
62
+ true
61
63
  end
62
64
 
63
65
  def parse_playlist_type(line)
@@ -1,4 +1,4 @@
1
1
  # M3u8 provides parsing, generation, and validation of m3u8 playlists
2
2
  module M3u8
3
- VERSION = '0.5.2'
3
+ VERSION = '0.5.3'
4
4
  end
@@ -19,6 +19,18 @@ describe M3u8::Reader do
19
19
  expect(item.iframe).to be false
20
20
  expect(item.average_bandwidth).to be_nil
21
21
 
22
+ item = playlist.items[5]
23
+ expect(item).to be_a(M3u8::PlaylistItem)
24
+ expect(item.uri).to eq('hls/64k/64k.m3u8')
25
+ expect(item.program_id).to eq('1')
26
+ expect(item.width).to be_nil
27
+ expect(item.height).to be_nil
28
+ expect(item.resolution).to be_nil
29
+ expect(item.codecs).to eq('mp4a.40.2')
30
+ expect(item.bandwidth).to eq(6400)
31
+ expect(item.iframe).to be false
32
+ expect(item.average_bandwidth).to be_nil
33
+
22
34
  expect(playlist.items.size).to eq 6
23
35
 
24
36
  item = playlist.items.last
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: m3u8
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.2
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Seth Deckard
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-18 00:00:00.000000000 Z
11
+ date: 2015-02-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler