mirror of
https://github.com/moparisthebest/android.moparisthebest.org
synced 2024-11-15 21:55:00 -05:00
Raise RuntimeError when gist is unavailable
This commit is contained in:
parent
a8c9fb8d7a
commit
ef8392e267
@ -82,6 +82,9 @@ module Jekyll
|
||||
https.verify_mode = OpenSSL::SSL::VERIFY_NONE
|
||||
request = Net::HTTP::Get.new raw_uri.request_uri
|
||||
data = https.request request
|
||||
if data.code != 200
|
||||
raise RuntimeError, "Gist replied with #{data.code} for #{gist_url}"
|
||||
end
|
||||
data = data.body
|
||||
cache gist, file, data unless @cache_disabled
|
||||
data
|
||||
|
Loading…
Reference in New Issue
Block a user