Skip to content

Commit ff22ec8

Browse files
committed
Layout/EmptyLinesAroundMethodBody
This commit enables the Rubocop Layout/EmptyLinesAroundMethodBody cop and addresses all offenses.
1 parent ee29954 commit ff22ec8

30 files changed

+0
-34
lines changed

.rubocop_todo.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,6 @@ Layout/EmptyLineAfterGuardClause:
3030
Layout/EmptyLineAfterMagicComment:
3131
Enabled: false
3232

33-
# This cop supports safe auto-correction (--auto-correct).
34-
Layout/EmptyLinesAroundMethodBody:
35-
Enabled: false
36-
3733
# This cop supports safe auto-correction (--auto-correct).
3834
# Configuration parameters: EnforcedStyle.
3935
# SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines

lib/puppet/application.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,6 @@ def deprecated?
399399
# @return [void]
400400
# @api public
401401
def run
402-
403402
# I don't really like the names of these lifecycle phases. It would be nice to change them to some more meaningful
404403
# names, and make deprecated aliases. --cprice 2012-03-16
405404

lib/puppet/configurer/downloader.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ def evaluate
4040

4141
def initialize(name, path, source, ignore = nil, environment = nil, source_permissions = :ignore)
4242
@name, @path, @source, @ignore, @environment, @source_permissions = name, path, source, ignore, environment, source_permissions
43-
4443
end
4544

4645
def file

lib/puppet/datatypes.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,6 @@ def self.create_type(type_name, &block)
133133
rescue StandardError => e
134134
raise ArgumentError, _("Data Type Load Error for type '%{type_name}': %{message}") % {type_name: type_name, message: e.message}
135135
end
136-
137136
end
138137

139138
def self.create_loaded_type(type_name, loader, &block)

lib/puppet/external/dot.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,6 @@ def pop
199199
end
200200

201201
def to_s(t = '')
202-
203202
# This code is totally incomprehensible; it needs to be replaced!
204203

205204
label = @options['shape'] != 'record' && @ports.length == 0 ?

lib/puppet/forge/errors.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,6 @@ def initialize(options)
102102
#
103103
# @return [String] the multiline version of the error message
104104
def multiline
105-
106105
message = []
107106
message << _('Request to Puppet Forge failed.')
108107
message << _(' The server being queried was %{uri}') % { uri: @uri }

lib/puppet/interface/action.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,6 @@ def deprecated?
222222
attr_reader :when_invoked
223223

224224
def when_invoked=(block)
225-
226225
internal_name = "#{@name} implementation, required on Ruby 1.8".to_sym
227226

228227
arity = @positional_arg_count = block.arity

lib/puppet/module_tool.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,6 @@ def self.set_option_defaults(options)
132132

133133
# Note: environment will have expanded the path
134134
options[:target_dir] = face_environment.full_modulepath.first
135-
136135
end
137136

138137
# Given a hash of options, we should discover or create a

lib/puppet/parser/ast/pops_bridge.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,6 @@ def initialize(program_model, context = {})
8686
# efficient as it avoids one full scan of all logic via recursive enumeration/yield)
8787
#
8888
def instantiate(modname)
89-
9089
@program_model.definitions.map do |d|
9190
case d
9291
when Puppet::Pops::Model::HostClassDefinition

lib/puppet/pops/evaluator/runtime3_resource_support.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ module Runtime3ResourceSupport
77
CLASS_STRING = 'class'
88

99
def self.create_resources(file, line, scope, virtual, exported, type_name, resource_titles, evaluated_parameters)
10-
1110
env = scope.environment
1211
# loader = Adapters::LoaderAdapter.loader_for_model_object(o, scope)
1312

0 commit comments

Comments
 (0)