Skip to content

Commit 26d8de3

Browse files
committed
Use rubocop autocorrect
1 parent c086c02 commit 26d8de3

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/github_action_check_run_formatter.rb

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
module Pronto
55
module Formatter
66
class GithubActionCheckRunFormatter < Base
7-
87
attr_accessor :messages, :repo, :sha, :check_run
98

109
def format(messages, repo, _)
@@ -23,7 +22,7 @@ def client
2322
@client ||= Octokit::Client.new(
2423
api_endpoint: config.github_api_endpoint,
2524
web_endpoint: config.github_web_endpoint,
26-
access_token: ENV.fetch('GITHUB_TOKEN') { config.github_access_token },
25+
access_token: ENV.fetch('GITHUB_TOKEN') { config.github_access_token }
2726
)
2827
end
2928

@@ -52,7 +51,7 @@ def create_check_run(runner, runner_messages)
5251
started_at: Time.now.iso8601,
5352
status: :completed,
5453
completed_at: Time.now.iso8601,
55-
accept: 'application/vnd.github.antiope-preview+json',
54+
accept: 'application/vnd.github.antiope-preview+json'
5655
)
5756
end
5857

@@ -72,14 +71,13 @@ def repo_slug
7271
event = JSON.parse(File.read(ENV.fetch('GITHUB_EVENT_PATH')))
7372
event.fetch('repository').fetch('full_name')
7473
else
75-
config.github_slug || fail('no github.slug in pronto config')
74+
config.github_slug || raise('no github.slug in pronto config')
7675
end
7776
end
7877

7978
def messages_by_runner
8079
@messages_by_runner ||= messages.uniq.group_by(&:runner)
8180
end
82-
8381
end
8482
end
8583
end

0 commit comments

Comments
 (0)