From 1e46f17b4f8094948b6087f28426b8c0dd0332a9 Mon Sep 17 00:00:00 2001 From: Kyrylo Silin Date: Mon, 25 Feb 2019 00:25:43 +0200 Subject: [PATCH] rubocop: fix offences of the Layout/EmptyLinesAroundMethodBody cop --- .rubocop_todo.yml | 7 ------- lib/pry/code_object.rb | 1 - lib/pry/indent.rb | 1 - 3 files changed, 9 deletions(-) diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index eceb3fad..de781467 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -13,13 +13,6 @@ Gemspec/RequiredRubyVersion: Exclude: - 'pry.gemspec' -# Offense count: 2 -# Cop supports --auto-correct. -Layout/EmptyLinesAroundMethodBody: - Exclude: - - 'lib/pry/code_object.rb' - - 'lib/pry/indent.rb' - # Offense count: 16 # Cop supports --auto-correct. # Configuration parameters: EnforcedStyle. diff --git a/lib/pry/code_object.rb b/lib/pry/code_object.rb index e8ed1ab1..2ffb17a7 100644 --- a/lib/pry/code_object.rb +++ b/lib/pry/code_object.rb @@ -112,7 +112,6 @@ class Pry # lookup variables and constants and `self` that are not modules def default_lookup - # we skip instance methods as we want those to fall through to method_or_class_lookup() if safe_to_evaluate?(str) && !looks_like_an_instance_method?(str) obj = target.eval(str) diff --git a/lib/pry/indent.rb b/lib/pry/indent.rb index 733a795e..5942c6f6 100644 --- a/lib/pry/indent.rb +++ b/lib/pry/indent.rb @@ -193,7 +193,6 @@ class Pry # @return [Array[Integer]] # def indentation_delta(tokens) - # We need to keep track of whether we've seen a "for" on this line because # if the line ends with "do" then that "do" should be discounted (i.e. we're # only opening one level not two) To do this robustly we want to keep track