diff --git a/rubocop.rb b/rubocop.rb index 2ed6945..548a9a8 100644 --- a/rubocop.rb +++ b/rubocop.rb @@ -63,7 +63,7 @@ def self.request(request_class, path, params = nil) # Figure out which ruby files have changed and run Rubocop on them -github_event = JSON.load_file(ENV.fetch("GITHUB_EVENT_PATH")) +github_event = JSON.parse(File.read(ENV.fetch("GITHUB_EVENT_PATH"))) pr_number = github_event.fetch("pull_request").fetch("number") owner_and_repository = ENV.fetch("GITHUB_REPOSITORY")