haml_lint 0.25.0 → 0.25.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2ec594ab38cde43b4bfc77c30d2d01cdaa8efcce
4
- data.tar.gz: 91068f84316b31511721b023a677609085796314
3
+ metadata.gz: bf05f1a1e2ec9d5ca6b6a6cd1ae398c8bf99f394
4
+ data.tar.gz: 39ea41022301f4ec279256bf6a9bfb930b786e25
5
5
  SHA512:
6
- metadata.gz: 4d852491b8757d078d5285d18a54017d70589fc98cc4d68e30e6d73be239e704dcf5fd0575fd7756bbfb4807fa68abdfe4fb361636e712423ad4614b9964e8df
7
- data.tar.gz: 775dc9d01056561a235508e7d4dee8af74fff6484424270796ecb2ab1fb2c0e17d61917d3ad6c2d8358b9688d88e84851e7e71678476d42f0ccad7c7e76f7d31
6
+ metadata.gz: 5ff5514837ce5b08d1571e2c61fe26b8fd9b26c063b7582cfafecb353bc308988bc9c64773b932821efd7d5122b2b64babd200dc5f69f2e1df2ef59874a6b063
7
+ data.tar.gz: 08ca2d1c74ae2c561734f6c69e65257e0ee8a64658e919be2875c367a83b217422e4dfa8fb7efce137f3cda118fed35d9e53de00fb4371046360aab39d6b8e67
@@ -16,7 +16,7 @@ module HamlLint
16
16
  # @param files [Array<String>] files that were linted
17
17
  # @param fail_level [Symbol] the severity level to fail on
18
18
  # @param reporter [HamlLint::Reporter] the reporter for the report
19
- def initialize(lints = [], files = [], fail_level = :warning, reporter:)
19
+ def initialize(lints = [], files = [], fail_level = :warning, reporter: nil)
20
20
  @lints = lints.sort_by { |l| [l.filename, l.line] }
21
21
  @files = files
22
22
  @fail_level = Severity.new(fail_level)
@@ -1,5 +1,6 @@
1
1
  module HamlLint::Tree
2
2
  # Represents a tag node in a HAML document.
3
+ # rubocop:disable ClassLength
3
4
  class TagNode < Node
4
5
  # Computed set of attribute hashes code.
5
6
  #
@@ -234,7 +235,9 @@ module HamlLint::Tree
234
235
  private
235
236
 
236
237
  def existing_attributes
237
- parsed_attributes.children.collect do |parsed_attribute|
238
+ parsed_attrs = parsed_attributes
239
+ return {} unless parsed_attrs.respond_to?(:children)
240
+ parsed_attrs.children.collect do |parsed_attribute|
238
241
  parsed_attribute.children.first.to_a.first
239
242
  end
240
243
  end
@@ -2,5 +2,5 @@
2
2
 
3
3
  # Defines the gem version.
4
4
  module HamlLint
5
- VERSION = '0.25.0'.freeze
5
+ VERSION = '0.25.1'.freeze
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: haml_lint
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.25.0
4
+ version: 0.25.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brigade Engineering
@@ -204,8 +204,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
204
204
  version: '0'
205
205
  requirements: []
206
206
  rubyforge_project:
207
- rubygems_version: 2.5.2
207
+ rubygems_version: 2.4.5.1
208
208
  signing_key:
209
209
  specification_version: 4
210
210
  summary: HAML lint tool
211
211
  test_files: []
212
+ has_rdoc: