thirteen_f 0.2.9 → 0.3.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: e0db316f9865f8c0c7d2628b28118744fccc6f21df261a976d921e9754b9945b
4
- data.tar.gz: 7957baae02039d937ac104742a7eec0c3a1bb3e52d4609e390bc41be25dafa3e
3
+ metadata.gz: 6e093431c9735d54ad5dfcfcf9f7a6a0b05dfbb91e3a3ef7ea3b52967907de11
4
+ data.tar.gz: d0abf210d710d1bf5876291d6d976ce388cf68597a2729020d602de9db96b8ce
5
5
  SHA512:
6
- metadata.gz: 775bcf2a5c88f3eab298839deb4b37c155f1c470b88bde87f64d54c64746d4ecf46f5d36125abe9570fbd9bfb56a4b67f9a25a7608e1c68847ae0fdc69a8f4e2
7
- data.tar.gz: 2bc0bbbe45a40ff0e35160094f05fc2dcd8d7cede3480b2bd2442d2bd3f517559e63dfec3f11ac5ed3333f16e1d300ac24a1c000ba7449109672dfc6aa5b946d
6
+ metadata.gz: ed391b2b422b3254814334d29b83af10f5e47cbe0f4ca73726cdb5fad2987a571cd32f19f8ea8360515867fcd8f33f55fb8437a4346119c3ec7182d5dbf0d996
7
+ data.tar.gz: be535e2cc291eb3fe56ccaeb9c987f8925f19b34572b5206614b441876351544d7398abfe5784d009f79f71462ba501e52c7d5b004b8843043a8122c61aa8852
@@ -10,20 +10,15 @@ class ThirteenF
10
10
 
11
11
  def self.from_xml_filing(filing)
12
12
  return nil unless filing.table_xml_url
13
- response = HTTP.get filing.table_xml_url
14
- xml_doc = Nokogiri::XML response.to_s
15
- xml_doc.search('infoTable').map do |info_table|
16
- position = new filing: filing
17
- position.attributes_from_info_table(info_table)
18
- position
19
- end
13
+ from_xml_url(filing.table_xml_url, filing: filing)
20
14
  end
21
15
 
22
- def self.from_xml_url(table_xml_url)
16
+ def self.from_xml_url(table_xml_url, filing: nil)
23
17
  response = HTTP.get table_xml_url
24
18
  xml_doc = Nokogiri::XML response.to_s
25
- xml_doc.search('infoTable').map do |info_table|
26
- position = new
19
+ xml_doc.remove_namespaces!
20
+ xml_doc.search("//infoTable").map do |info_table|
21
+ position = new filing: filing
27
22
  position.attributes_from_info_table(info_table)
28
23
  position
29
24
  end
@@ -1,3 +1,3 @@
1
1
  class ThirteenF
2
- VERSION = "0.2.9"
2
+ VERSION = "0.3.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thirteen_f
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.9
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - fordfischer
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-03-31 00:00:00.000000000 Z
11
+ date: 2020-04-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: minitest