actionview 5.1.6.2 → 5.1.7.rc1

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

Potentially problematic release.


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

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b5414a4839d0c0bd964f57ef6378875b441469f986c6b9e75ef42abc79032fec
4
- data.tar.gz: 3a58ea48d85ff32cb87f4c68277ad98bf7cd8eaacca9c0338979bdbebe715a68
3
+ metadata.gz: 11606a0e8fde64c7447a46295d8e85626f80f1e600fbfd45bc23505ce6204bef
4
+ data.tar.gz: ad3b990d0c00c37b2d3773bbaa865cd68fd08301653db001842ffa05b81af1bb
5
5
  SHA512:
6
- metadata.gz: 18b78472dd254ea1e11874805e4b834e61afe3989869de317e41e7e9d1d276c44971b12cdf0a91913360ce4e3529ee8a3f43f3a6d5131947a0cd03960210767e
7
- data.tar.gz: 1e2555eab93c2a63142ace9b88936d65d143ac84ae2b2c535ffcdd552aea4313bf3d9de0da67ca63f6cf192a12c8a89232c4dd458c3e446de5d2362e5a3b4879
6
+ metadata.gz: d146430764d585a5ea1f77f8b2498b2f044d9a4006c06082ca781b21d0ac6479daa5e8073423311d09c94c20ac34a4914d8556e75d53b9220f94a63fce08a002
7
+ data.tar.gz: 487e7a9c242b91bbd57fc4ef5517d3051ec98092f94fba2bce101ba6678604593467765ae80fa57f14ed082fcf5ea1906bb4db93c4821534f8dd27c01dcacc9b
data/CHANGELOG.md CHANGED
@@ -1,3 +1,16 @@
1
+ ## Rails 5.1.7.rc1 (March 22, 2019) ##
2
+
3
+ * Fix issue with `button_to`'s `to_form_params`
4
+
5
+ `button_to` was throwing exception when invoked with `params` hash that
6
+ contains symbol and string keys. The reason for the exception was that
7
+ `to_form_params` was comparing the given symbol and string keys.
8
+
9
+ The issue is fixed by turning all keys to strings inside
10
+ `to_form_params` before comparing them.
11
+
12
+ *Georgi Georgiev*
13
+
1
14
  ## Rails 5.1.6.2 (March 11, 2019) ##
2
15
 
3
16
  * No changes.
@@ -43,9 +43,8 @@ module ActionView
43
43
  # Create a dependency tree for template named +name+.
44
44
  def tree(name, finder, partial = false, seen = {})
45
45
  logical_name = name.gsub(%r|/_|, "/")
46
- finder.formats = [finder.rendered_format] if finder.rendered_format
47
46
 
48
- if template = finder.disable_cache { finder.find_all(logical_name, [], partial, []).first }
47
+ if template = find_template(finder, logical_name, [], partial, [])
49
48
  finder.rendered_format ||= template.formats.first
50
49
 
51
50
  if node = seen[template.identifier] # handle cycles in the tree
@@ -67,6 +66,17 @@ module ActionView
67
66
  seen[name] ||= Missing.new(name, logical_name, nil)
68
67
  end
69
68
  end
69
+
70
+ private
71
+ def find_template(finder, *args)
72
+ finder.disable_cache do
73
+ if format = finder.rendered_format
74
+ finder.find_all(*args, formats: [format]).first || finder.find_all(*args).first
75
+ else
76
+ finder.find_all(*args).first
77
+ end
78
+ end
79
+ end
70
80
  end
71
81
 
72
82
  class Node
@@ -7,8 +7,8 @@ module ActionView
7
7
  module VERSION
8
8
  MAJOR = 5
9
9
  MINOR = 1
10
- TINY = 6
11
- PRE = "2"
10
+ TINY = 7
11
+ PRE = "rc1"
12
12
 
13
13
  STRING = [MAJOR, MINOR, TINY, PRE].compact.join(".")
14
14
  end
@@ -11,7 +11,6 @@ module ActionView
11
11
  # * <tt>:partial</tt> - See <tt>ActionView::PartialRenderer</tt>.
12
12
  # * <tt>:file</tt> - Renders an explicit template file (this used to be the old default), add :locals to pass in those.
13
13
  # * <tt>:inline</tt> - Renders an inline template similar to how it's done in the controller.
14
- # * <tt>:text</tt> - Renders the text passed in out.
15
14
  # * <tt>:plain</tt> - Renders the text passed in out. Setting the content
16
15
  # type as <tt>text/plain</tt>.
17
16
  # * <tt>:html</tt> - Renders the HTML safe string passed in out, otherwise
@@ -610,7 +610,7 @@ module ActionView
610
610
  # suitable for use as the names and values of form input fields:
611
611
  #
612
612
  # to_form_params(name: 'David', nationality: 'Danish')
613
- # # => [{name: :name, value: 'David'}, {name: 'nationality', value: 'Danish'}]
613
+ # # => [{name: 'name', value: 'David'}, {name: 'nationality', value: 'Danish'}]
614
614
  #
615
615
  # to_form_params(country: {name: 'Denmark'})
616
616
  # # => [{name: 'country[name]', value: 'Denmark'}]
@@ -642,7 +642,7 @@ module ActionView
642
642
  params.push(*to_form_params(value, array_prefix))
643
643
  end
644
644
  else
645
- params << { name: namespace, value: attribute.to_param }
645
+ params << { name: namespace.to_s, value: attribute.to_param }
646
646
  end
647
647
 
648
648
  params.sort_by { |pair| pair[:name] }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actionview
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.1.6.2
4
+ version: 5.1.7.rc1
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: 2019-03-13 00:00:00.000000000 Z
11
+ date: 2019-03-22 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.1.6.2
19
+ version: 5.1.7.rc1
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.1.6.2
26
+ version: 5.1.7.rc1
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: builder
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.1.6.2
95
+ version: 5.1.7.rc1
96
96
  type: :development
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.1.6.2
102
+ version: 5.1.7.rc1
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.1.6.2
109
+ version: 5.1.7.rc1
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.1.6.2
116
+ version: 5.1.7.rc1
117
117
  description: Simple, battle-tested conventions and helpers for building web pages.
118
118
  email: david@loudthinking.com
119
119
  executables: []
@@ -231,8 +231,8 @@ homepage: http://rubyonrails.org
231
231
  licenses:
232
232
  - MIT
233
233
  metadata:
234
- source_code_uri: https://github.com/rails/rails/tree/v5.1.6.2/actionview
235
- changelog_uri: https://github.com/rails/rails/blob/v5.1.6.2/actionview/CHANGELOG.md
234
+ source_code_uri: https://github.com/rails/rails/tree/v5.1.7.rc1/actionview
235
+ changelog_uri: https://github.com/rails/rails/blob/v5.1.7.rc1/actionview/CHANGELOG.md
236
236
  post_install_message:
237
237
  rdoc_options: []
238
238
  require_paths:
@@ -244,9 +244,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
244
244
  version: 2.2.2
245
245
  required_rubygems_version: !ruby/object:Gem::Requirement
246
246
  requirements:
247
- - - ">="
247
+ - - ">"
248
248
  - !ruby/object:Gem::Version
249
- version: '0'
249
+ version: 1.3.1
250
250
  requirements:
251
251
  - none
252
252
  rubygems_version: 3.0.1