class Danger::RubyGemsClient

Constants

API_URL
DUMMY_VERSION

Public Class Methods

latest_danger_version() click to toggle source
# File lib/danger/clients/rubygems_client.rb, line 6
def self.latest_danger_version
  require "json"
  json = JSON.parse(Faraday.get(API_URL).body)
  json.fetch("version") { DUMMY_VERSION }
rescue StandardError => _e
  DUMMY_VERSION
end