Skip to content

Commit

Permalink
fixes for rubocop
Browse files Browse the repository at this point in the history
  • Loading branch information
digitaltom committed Sep 29, 2017
1 parent 9858e20 commit 09e6b1a
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
8 changes: 8 additions & 0 deletions .rubocop_todo.yml
Expand Up @@ -101,6 +101,14 @@ Lint/IneffectiveAccessModifier:
Exclude:
- 'lib/suse/connect/credentials.rb'

Lint/RescueWithoutErrorClass:
Exclude:
- 'lib/suse/connect/hwinfo/arm64.rb'
- 'lib/suse/connect/hwinfo/x86.rb'
- 'lib/suse/toolkit/curlrc_dotfile.rb'
- 'lib/suse/toolkit/utilities.rb'
- 'bin/SUSEConnect'

# Offense count: 4
# Cop supports --auto-correct.
Lint/UnneededDisable:
Expand Down
2 changes: 1 addition & 1 deletion lib/suse/connect/connection.rb
Expand Up @@ -36,7 +36,7 @@ def initialize(endpoint, language: nil, insecure: false, debug: false, verify_ca
self.verify_callback = verify_callback
end

VERB_TO_CLASS.keys.each do |name_for_method|
VERB_TO_CLASS.each_key do |name_for_method|
define_method name_for_method do |path, auth: nil, params: {}|
@auth = auth
response = json_request(name_for_method.downcase.to_sym, path, params)
Expand Down
2 changes: 1 addition & 1 deletion lib/suse/connect/errors.rb
Expand Up @@ -19,7 +19,7 @@ class BaseProductDeactivationError < StandardError; end
# Used by YaST already, do not refactor without consulting them!
# (Error handling: #response, #code, #message, #service)
class ApiError < StandardError
attr_accessor :response, :message
attr_accessor :response

# @param response [Net::HTTPResponse] the HTTP response error returned
# by API request
Expand Down
2 changes: 1 addition & 1 deletion prophet/ci_executor.rb
Expand Up @@ -29,7 +29,7 @@ def text_status
# Project
class Project

attr_accessor :name, :steps, :status
attr_accessor :name, :steps

def initialize(name: nil, steps: [])
@name = name
Expand Down

0 comments on commit 09e6b1a

Please sign in to comment.