cyborg 0.4.5 → 0.4.6

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: 77e51259530bcf60b10cbf276842a5191cdf536d
4
- data.tar.gz: d4982161be378dc8c619ffdb87f643955779a7f7
3
+ metadata.gz: 8d8b08048534b62f35c83ac4f8c353086245959a
4
+ data.tar.gz: 4c60ed9cb6a9c40ca3f1de57c10fd6ae99ec67b1
5
5
  SHA512:
6
- metadata.gz: 71e9196b88a51ea10c9df4aa18fb1e2bb11d7b541eda25670098d47073367f38f8adc91c31c41309202baa96a72d3e6691be874007cc10ba7e6f3e20ad8b13f1
7
- data.tar.gz: 73dd8ee992a169825af02e800ce985a9b4bc0567e0dbd62012f58db7186adfd2f70f2d33b12a4ee6b1c7253c3a97417566435fc1603c866350ebfbb7e15150bb
6
+ metadata.gz: 1ea65d049e68aedfc0977cd759245e3ccad938b61b8ab1c77e381bf4514010f3cc809cfae224c4d458a55e03c5f1cd219a282cb01166b7c63c667aed2b460c07
7
+ data.tar.gz: a332f85c88c83f073c15d5b174ff974cd6ce19317398d63bf8e832241b722303998f1319ba8c336ea39a978836c82ad438519d529f78b7e308d75257f313c7a4
@@ -11,8 +11,9 @@ module Cyborg
11
11
  tags = ''
12
12
 
13
13
  stylesheet_url(args).each do |url|
14
- url += '.gz' if Cyborg.production?
15
- tags += stylesheet_link_tag(url, options)
14
+ tag = stylesheet_link_tag url, options
15
+ tag.gsub(/\.css/i, ".css.gz") if Cyborg.production? && request.accept_encoding =~ /gzip/i
16
+ tags += tag
16
17
  end
17
18
 
18
19
  tags.html_safe
@@ -24,8 +25,9 @@ module Cyborg
24
25
 
25
26
  puts "searching for: #{javascript_url(args)}"
26
27
  javascript_url(args).each do |url|
27
- url += '.gz' if Cyborg.production?
28
- tags += javascript_include_tag(url, options)
28
+ tag = javascript_include_tag url, options
29
+ tag.gsub(/\.js/i, ".js.gz") if Cyborg.production? && request.accept_encoding =~ /gzip/i
30
+ tags += tag
29
31
  end
30
32
 
31
33
  tags.html_safe
@@ -1,3 +1,3 @@
1
1
  module Cyborg
2
- VERSION = "0.4.5"
2
+ VERSION = "0.4.6"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cyborg
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.5
4
+ version: 0.4.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-08-11 00:00:00.000000000 Z
11
+ date: 2016-09-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sass