actionpack 5.0.1.rc2 → 5.0.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of actionpack might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 78120e6032355f83a541aea2b9244d9af059a336
4
- data.tar.gz: a7363d48f334f9ce6da98514d719349041c400df
3
+ metadata.gz: adec2805e3c4f12afd7b77c089a935256fe447a8
4
+ data.tar.gz: be1f90611b0af1bf8d080e774082fe5bd1e8089c
5
5
  SHA512:
6
- metadata.gz: 516c9c4d7c5993d2b6dbd6ff382fae0aff3b1789065431988f00c2a556ab5855b74e054575b1ec3f696479085369098973b3f0354d07300ae9f482562531b9d2
7
- data.tar.gz: 8c7bc165fea6532ec1caec33fa10f9995e5af2b5c665c935c7e230e5bc6af552448ce3f00eedee229ca1b7716e5856f688835c49c7dd7919915335587dcc7571
6
+ metadata.gz: d04129d8134b698dc545544d196cb480bca76a8b273f5d78dba8fc34d643f9d1c52a45989c7dbf0c48ca0c272ea74d4579e77278e8a49db49e3bf27bc4052280
7
+ data.tar.gz: 6b33c7eda6aba889bda90ceb08c9f085a96cce9a4c5e49dd257b6f09edb8aaed9e68336e881f85f4316056e3762dcc9061bb262ba313ce99203140b120e83a32
@@ -1,3 +1,13 @@
1
+ ## Rails 5.0.1 (December 21, 2016) ##
2
+
3
+ * Restored correct `charset` behavior on `send_data` and `send_file`: while
4
+ they should pass along any supplied value, they should not add a default.
5
+
6
+ Fixes #27344.
7
+
8
+ *Matthew Draper*
9
+
10
+
1
11
  ## Rails 5.0.1.rc2 (December 10, 2016) ##
2
12
 
3
13
  * Move `cookies`, `flash`, and `session` methods back to
@@ -70,7 +70,6 @@ module ActionController #:nodoc:
70
70
  send_file_headers! options
71
71
 
72
72
  self.status = options[:status] || 200
73
- self.content_type = options[:type] if options.key?(:type)
74
73
  self.content_type = options[:content_type] if options.key?(:content_type)
75
74
  response.send_file path
76
75
  end
@@ -113,6 +112,9 @@ module ActionController #:nodoc:
113
112
  def send_file_headers!(options)
114
113
  type_provided = options.has_key?(:type)
115
114
 
115
+ self.content_type = DEFAULT_SEND_FILE_TYPE
116
+ response.sending_file = true
117
+
116
118
  content_type = options.fetch(:type, DEFAULT_SEND_FILE_TYPE)
117
119
  raise ArgumentError, ":type option required" if content_type.nil?
118
120
 
@@ -137,8 +139,6 @@ module ActionController #:nodoc:
137
139
 
138
140
  headers['Content-Transfer-Encoding'] = 'binary'
139
141
 
140
- response.sending_file = true
141
-
142
142
  # Fix a problem with IE 6.0 on opening downloaded files:
143
143
  # If Cache-Control: no-cache is set (which Rails does by default),
144
144
  # IE removes the file it just downloaded from its cache immediately
@@ -227,7 +227,9 @@ module ActionDispatch # :nodoc:
227
227
  return unless content_type
228
228
  new_header_info = parse_content_type(content_type.to_s)
229
229
  prev_header_info = parsed_content_type_header
230
- set_content_type new_header_info.mime_type, new_header_info.charset || prev_header_info.charset || self.class.default_charset
230
+ charset = new_header_info.charset || prev_header_info.charset
231
+ charset ||= self.class.default_charset unless prev_header_info.mime_type
232
+ set_content_type new_header_info.mime_type, charset
231
233
  end
232
234
 
233
235
  # Sets the HTTP response's content MIME type. For example, in the controller
@@ -8,7 +8,7 @@ module ActionPack
8
8
  MAJOR = 5
9
9
  MINOR = 0
10
10
  TINY = 1
11
- PRE = "rc2"
11
+ PRE = nil
12
12
 
13
13
  STRING = [MAJOR, MINOR, TINY, PRE].compact.join(".")
14
14
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actionpack
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.1.rc2
4
+ version: 5.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Heinemeier Hansson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-12-09 00:00:00.000000000 Z
11
+ date: 2016-12-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 5.0.1.rc2
19
+ version: 5.0.1
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 5.0.1.rc2
26
+ version: 5.0.1
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rack
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -92,28 +92,28 @@ dependencies:
92
92
  requirements:
93
93
  - - '='
94
94
  - !ruby/object:Gem::Version
95
- version: 5.0.1.rc2
95
+ version: 5.0.1
96
96
  type: :runtime
97
97
  prerelease: false
98
98
  version_requirements: !ruby/object:Gem::Requirement
99
99
  requirements:
100
100
  - - '='
101
101
  - !ruby/object:Gem::Version
102
- version: 5.0.1.rc2
102
+ version: 5.0.1
103
103
  - !ruby/object:Gem::Dependency
104
104
  name: activemodel
105
105
  requirement: !ruby/object:Gem::Requirement
106
106
  requirements:
107
107
  - - '='
108
108
  - !ruby/object:Gem::Version
109
- version: 5.0.1.rc2
109
+ version: 5.0.1
110
110
  type: :development
111
111
  prerelease: false
112
112
  version_requirements: !ruby/object:Gem::Requirement
113
113
  requirements:
114
114
  - - '='
115
115
  - !ruby/object:Gem::Version
116
- version: 5.0.1.rc2
116
+ version: 5.0.1
117
117
  description: Web apps on Rails. Simple, battle-tested conventions for building and
118
118
  testing MVC web applications. Works with any Rack-compatible server.
119
119
  email: david@loudthinking.com
@@ -292,9 +292,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
292
292
  version: 2.2.2
293
293
  required_rubygems_version: !ruby/object:Gem::Requirement
294
294
  requirements:
295
- - - ">"
295
+ - - ">="
296
296
  - !ruby/object:Gem::Version
297
- version: 1.3.1
297
+ version: '0'
298
298
  requirements:
299
299
  - none
300
300
  rubyforge_project:
@@ -303,3 +303,4 @@ signing_key:
303
303
  specification_version: 4
304
304
  summary: Web-flow and rendering framework putting the VC in MVC (part of Rails).
305
305
  test_files: []
306
+ has_rdoc: