sprockets 4.0.1 → 4.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
  SHA256:
3
- metadata.gz: 7bbf26f3dfff9a86ca4b4407072f1786fafed4040a2f3f25c875842dc834bdcf
4
- data.tar.gz: 5a6dd07a6568dca18b5d1eca850a1e3a78030c20a6530781d8a16ac31c25649c
3
+ metadata.gz: a4743994bc846327ac80bde662aa5a26fd95ce5cca2dd149deafe0fe94b6bf00
4
+ data.tar.gz: 454485ef7d2c5aac60c69b7d7042ed1b74245afecfeadc72c7e9bc290dc8b5b8
5
5
  SHA512:
6
- metadata.gz: fa3fb386fe8ded820388ff86e1b505736dadcf5e072fedc124c8635955af70df9db7386ce66f4e2d4f412c652e88df9c8dc93a451ac31b2982f0457393911202
7
- data.tar.gz: 3dde983e601b16c7b4bc71343543c69b7b8787b70daaaad711bc45ec47b4dd53507d67f6b6a9c1f8de1a7069bfbc12f72c96a0eaa088f976187fe9d4ca8f78f8
6
+ metadata.gz: c6d61894b3f53a76bf1f04c3f2fe74143b33e43d5fbdc3db216bdf0ad88d06f8a73fc61bd12071ee79e8aab49b36cb14685f6bb2d86582387cbc5522cef305a3
7
+ data.tar.gz: ca2bff624116f6de55ce4f9c6371be9d71245d2883c4837cf5a1b4969006fbdf8507b358c7986cccb03edb00711367538176ed2701a1e725cde1206163c64e2c
@@ -2,6 +2,10 @@
2
2
 
3
3
  Get upgrade notes from Sprockets 3.x to 4.x at https://github.com/rails/sprockets/blob/master/UPGRADING.md
4
4
 
5
+ ## 4.0.2
6
+
7
+ - Fix `etag` and digest path compilation that were generating string with invalid digest since 4.0.1.
8
+
5
9
  ## 4.0.1
6
10
 
7
11
  - Fix for Ruby 2.7 keyword arguments warning in `base.rb`. [#660](https://github.com/rails/sprockets/pull/660)
@@ -135,7 +135,13 @@ module Sprockets
135
135
 
136
136
  # Pubic: ETag String of Asset.
137
137
  def etag
138
- DigestUtils.pack_hexdigest(environment_version + digest)
138
+ version = environment_version
139
+
140
+ if version && version != ""
141
+ DigestUtils.hexdigest(version + digest)
142
+ else
143
+ DigestUtils.pack_hexdigest(digest)
144
+ end
139
145
  end
140
146
 
141
147
  # Public: Returns String base64 digest of source.
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Sprockets
3
- VERSION = "4.0.1"
3
+ VERSION = "4.0.2"
4
4
  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: 4.0.1
4
+ version: 4.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sam Stephenson