Skip to content

Commit 5509e6c

Browse files
committed
Fix rubocop violations
1 parent 2dee86a commit 5509e6c

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/better_html/tokenizer/html_lodash.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def scan!
3333
captures = scan_pattern.match(scanned).captures
3434

3535
if (pre_match = captures[0])
36-
add_text(pre_match) if pre_match.present? # rubocop:disable Metrics/BlockNesting
36+
add_text(pre_match) if pre_match.present?
3737
end
3838

3939
match = captures[1]

lib/better_html/tokenizer/location.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def line_range
3939
def line_source_with_underline
4040
spaces = source_line.scan(/\A\s*/).first
4141
column_without_spaces = [column - spaces.length, 0].max
42-
underscore_length = (end_pos - begin_pos).clamp(1, (source_line.length - column_without_spaces))
42+
underscore_length = (end_pos - begin_pos).clamp(1, source_line.length - column_without_spaces)
4343
"#{source_line.gsub(/\A\s*/, "")}\n#{" " * column_without_spaces}#{"^" * underscore_length}"
4444
end
4545

0 commit comments

Comments
 (0)