Sha256: 8fb2d96e706a6466678b31bb67c559d28341e268ecfb974fba1750719047da09
Contents?: true
Size: 585 Bytes
Versions: 4
Compression:
Stored size: 585 Bytes
Contents
require "httparty" module Artifactory module GemImport module GemSpecs class Downloader def self.call(url, headers: {}) new(url, headers).call end attr_reader :url, :headers def initialize(url, headers) @url = url @headers = headers end def call response = HTTParty.get url, headers: headers if response.success? response.body else response.error! end end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems