sprockets 2.12.3 → 2.12.5

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
- SHA1:
3
- metadata.gz: 4ac3ec814692936eab4dc58704519ca15c383880
4
- data.tar.gz: 1888571f870ed8cb1a4e7a36dd78b2c7079991ed
2
+ SHA256:
3
+ metadata.gz: 80bdc30a8aea68bb04398d467eea5a5e4cfe9b7dcef6ee41e2902debcec63342
4
+ data.tar.gz: 55a0f0b58e3e55c08ccfb30476017b814894b7ec98cf3bd22eecbc8bdcbe5c39
5
5
  SHA512:
6
- metadata.gz: 5a11411a3911b1bb069ec8b350e3017d96377f70a7a41b62db3b8da1616186c57dd31a9d746f01cc7b16c1e717dd7dfcc1c513a2d92420a4ddbc7f1ee292bdb0
7
- data.tar.gz: 036a48e5dc1c97776e9aa455e6b254ecfcd83edbd0cabc1c999c1b23f4881685458f9e2683c35e38d9ad72946facbefe05b2bdef962d9cc2ab9fa73c74780b82
6
+ metadata.gz: a3ee63f44b0391509f3e80b1c6b403abf52168a66910da726221b7b45c6c51187f86a7896df45e8b6c7bed68d5218ad7915fa79602e3cf7a23c32622d23ab8a5
7
+ data.tar.gz: da30a4f95ef0691cec504b73b1d832cec2577aa0b2905050e74ad9a89322c6568e3ec250a760ac3a6f2080f738e8ed1580e3ae7ff2a53e8623820d98fea00b2d
@@ -139,7 +139,9 @@ module Sprockets
139
139
  # Save asset to disk.
140
140
  def write_to(filename, options = {})
141
141
  # Gzip contents if filename has '.gz'
142
- options[:compress] ||= File.extname(filename) == '.gz'
142
+ unless options.key?(:compress)
143
+ options[:compress] = File.extname(filename) == '.gz' && File.extname(logical_path) != '.gz'
144
+ end
143
145
 
144
146
  FileUtils.mkdir_p File.dirname(filename)
145
147
 
@@ -18,7 +18,7 @@ module Sprockets
18
18
  # Defaults to `Digest::MD5`.
19
19
  attr_reader :digest_class
20
20
 
21
- # Assign a `Digest` implementation class. This maybe any Ruby
21
+ # Assign a `Digest` implementation class. This may be any Ruby
22
22
  # `Digest::` implementation such as `Digest::MD5` or
23
23
  # `Digest::SHA1`.
24
24
  #
@@ -90,7 +90,7 @@ module Sprockets
90
90
  #
91
91
  # http://example.org/assets/../../../etc/passwd
92
92
  #
93
- path.include?("..") || Pathname.new(path).absolute?
93
+ path.include?("..") || Pathname.new(path).absolute? || path.include?("://")
94
94
  end
95
95
 
96
96
  # Returns a 403 Forbidden response tuple
@@ -21,7 +21,9 @@ module Sprockets
21
21
  # Save asset to disk.
22
22
  def write_to(filename, options = {})
23
23
  # Gzip contents if filename has '.gz'
24
- options[:compress] ||= File.extname(filename) == '.gz'
24
+ unless options.key?(:compress)
25
+ options[:compress] = File.extname(filename) == '.gz' && File.extname(logical_path) != '.gz'
26
+ end
25
27
 
26
28
  FileUtils.mkdir_p File.dirname(filename)
27
29
 
@@ -1,3 +1,3 @@
1
1
  module Sprockets
2
- VERSION = "2.12.3"
2
+ VERSION = "2.12.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sprockets
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.12.3
4
+ version: 2.12.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sam Stephenson
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-10-28 00:00:00.000000000 Z
12
+ date: 2018-06-19 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: hike
@@ -241,6 +241,20 @@ dependencies:
241
241
  - - ">="
242
242
  - !ruby/object:Gem::Version
243
243
  version: '0'
244
+ - !ruby/object:Gem::Dependency
245
+ name: test-unit
246
+ requirement: !ruby/object:Gem::Requirement
247
+ requirements:
248
+ - - "~>"
249
+ - !ruby/object:Gem::Version
250
+ version: '3.1'
251
+ type: :development
252
+ prerelease: false
253
+ version_requirements: !ruby/object:Gem::Requirement
254
+ requirements:
255
+ - - "~>"
256
+ - !ruby/object:Gem::Version
257
+ version: '3.1'
244
258
  description: Sprockets is a Rack-based asset packaging system that concatenates and
245
259
  serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.
246
260
  email:
@@ -313,7 +327,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
313
327
  version: '0'
314
328
  requirements: []
315
329
  rubyforge_project: sprockets
316
- rubygems_version: 2.2.2
330
+ rubygems_version: 2.7.6
317
331
  signing_key:
318
332
  specification_version: 4
319
333
  summary: Rack-based asset packaging system