Skip to content

Commit 3815ab4

Browse files
authored
Fix ruby 2.7 deprecation warnings with ** (#443)
* Fix ruby 2.7 deprecation warnings with ** * dev in 2.6, test in 2.7 Co-authored-by: Neil Matatall <[email protected]>
1 parent 8d2c23c commit 3815ab4

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

.github/workflows/build.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
name: Build + Test
2-
on: [pull_request, push]
2+
on: [pull_request]
33

44
jobs:
55
build:
66
name: Build + Test
77
runs-on: ubuntu-latest
88
strategy:
99
matrix:
10-
ruby: [ '2.4', '2.5', '2.6' ]
10+
ruby: [ '2.4', '2.5', '2.6', '2.7' ]
1111

1212
steps:
1313
- uses: actions/checkout@v2

.ruby-version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.6.5
1+
2.6.6

lib/secure_headers/view_helper.rb

+4-4
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def nonced_style_tag(content_or_options = {}, &block)
2121
def nonced_stylesheet_link_tag(*args, &block)
2222
opts = extract_options(args).merge(nonce: _content_security_policy_nonce(:style))
2323

24-
stylesheet_link_tag(*args, opts, &block)
24+
stylesheet_link_tag(*args, **opts, &block)
2525
end
2626

2727
# Public: create a script tag using the content security policy nonce.
@@ -39,7 +39,7 @@ def nonced_javascript_tag(content_or_options = {}, &block)
3939
def nonced_javascript_include_tag(*args, &block)
4040
opts = extract_options(args).merge(nonce: _content_security_policy_nonce(:script))
4141

42-
javascript_include_tag(*args, opts, &block)
42+
javascript_include_tag(*args, **opts, &block)
4343
end
4444

4545
# Public: create a script Webpacker pack tag using the content security policy nonce.
@@ -49,7 +49,7 @@ def nonced_javascript_include_tag(*args, &block)
4949
def nonced_javascript_pack_tag(*args, &block)
5050
opts = extract_options(args).merge(nonce: _content_security_policy_nonce(:script))
5151

52-
javascript_pack_tag(*args, opts, &block)
52+
javascript_pack_tag(*args, **opts, &block)
5353
end
5454

5555
# Public: create a stylesheet Webpacker link tag using the content security policy nonce.
@@ -59,7 +59,7 @@ def nonced_javascript_pack_tag(*args, &block)
5959
def nonced_stylesheet_pack_tag(*args, &block)
6060
opts = extract_options(args).merge(nonce: _content_security_policy_nonce(:style))
6161

62-
stylesheet_pack_tag(*args, opts, &block)
62+
stylesheet_pack_tag(*args, **opts, &block)
6363
end
6464

6565
# Public: use the content security policy nonce for this request directly.

0 commit comments

Comments
 (0)