rubocop: fix offences of the Layout/ExtraSpacing cop

This commit is contained in:
Kyrylo Silin 2018-10-13 00:54:00 +08:00
parent 69c7b27f25
commit 4cc13f9a40
28 changed files with 56 additions and 61 deletions

View File

@ -272,12 +272,6 @@ Layout/EndAlignment:
- 'lib/pry/editor.rb'
- 'lib/pry/method.rb'
# Offense count: 53
# Cop supports --auto-correct.
# Configuration parameters: AllowForAlignment, ForceEqualSignAlignment.
Layout/ExtraSpacing:
Enabled: false
# Offense count: 9
# Cop supports --auto-correct.
# Configuration parameters: EnforcedStyle, IndentationWidth.

View File

@ -209,7 +209,7 @@ class Pry
# Pry.config.commands.alias_command "lM", "ls -M"
# @example Pass explicit description (overriding default).
# Pry.config.commands.alias_command "lM", "ls -M", :desc => "cutiepie"
def alias_command(match, action, options={})
def alias_command(match, action, options = {})
cmd = find_command(action) or fail "Command: `#{action}` not found"
original_options = cmd.options.dup

View File

@ -30,7 +30,8 @@ class Pry
def backtrace_level
@backtrace_level ||=
begin
bl = if opts[:ex].nil?
bl =
if opts[:ex].nil?
ex.bt_index
else
ex.bt_index = absolute_index_number(opts[:ex], ex.backtrace.size)