Skip to content

Commit 9bbd0b0

Browse files
committed
Fix an offense on Style/RedundantRegexpEscape
1 parent 858ca24 commit 9bbd0b0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/rubocop/cop/rails/content_tag.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ def autocorrect(corrector, node, preferred_method)
8181
def allowed_name?(argument)
8282
return false unless argument.str_type? || argument.sym_type?
8383

84-
!/^[a-zA-Z\-][a-zA-Z\-0-9]*$/.match?(argument.value)
84+
!/^[a-zA-Z-][a-zA-Z\-0-9]*$/.match?(argument.value)
8585
end
8686

8787
def correction_range(node)

0 commit comments

Comments
 (0)