html-proofer 3.0.1 → 3.0.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: 70b082d296e52d443233ecdca1b3636e58c49b29
4
- data.tar.gz: 6c9e8ba7f27a541fb9c2440e5f94ebc1e2dbff57
3
+ metadata.gz: 0a7f49545d18aa66bfc44b6c85120b9b3305b543
4
+ data.tar.gz: 7367e8fbc60ee450cb4e17a7eed6b5c4b7452f08
5
5
  SHA512:
6
- metadata.gz: d1d020ca9e6397f35de5050c5884d9596d94e8c3125674657468fbacf9fd52e6d709f45799c388d21a13b49d41f12c08a16827fa8dd4dcc7835e4b1a4d43ef99
7
- data.tar.gz: d998ed74d55fb1c0fc7464c05e0138c9b7b9c76beef011fb518918837355a3a57f56c624d8a75c2a3b17d6394074aa249f7c70d9d4eabe2b8a06920ece540d02
6
+ metadata.gz: 9627105a7aaa3b438798b0632066cb8affb3e6511fa54a8ae20e23ebda7918dbcb12fd7a75d3f5dcbbf7fd7d6e6f1ea7f9f47295d1d00e31cc263da0f6cbf0bf
7
+ data.tar.gz: 50179f9029022b5888329d030b2f27c7905ade5f0f88c5c2a39fac64aa6e946b9fa125163522b1512697920a5652d5f2914b70a4c5ac323862487d8ca9e1b98d
@@ -96,7 +96,12 @@ module HTMLProofer
96
96
  @logger.log :debug, "Checking #{klass.to_s.downcase} on #{path} ..."
97
97
  check = Object.const_get(klass).new(src, path, html, @options)
98
98
  check.run
99
- result[:external_urls].merge!(check.external_urls)
99
+ external_urls = check.external_urls
100
+ if @options[:url_swap]
101
+ external_urls = Hash[check.external_urls.map { |url, file| [swap(url, @options[:url_swap]), file] }]
102
+ end
103
+ puts check.external_urls
104
+ result[:external_urls].merge!(external_urls)
100
105
  result[:failures].concat(check.issues)
101
106
  end
102
107
  end
@@ -1,3 +1,3 @@
1
1
  module HTMLProofer
2
- VERSION = '3.0.1'
2
+ VERSION = '3.0.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: html-proofer
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.1
4
+ version: 3.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Garen Torikian