FIX: catch proper exception

This commit is contained in:
Régis Hanol 2019-05-25 00:14:54 +02:00 committed by GitHub
parent 5bfeef7705
commit 4e5305cb67
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -38,7 +38,7 @@ class DiscourseIpInfo
path = gz_file.path.sub(/\.gz\z/, "")
FileUtils.mv(path, mmdb_path(name))
rescue HTTPError => e
rescue OpenURI::HTTPError => e
Rails.logger.warn("MaxMindDB (#{name}) could not be downloaded: #{e}")
end
ensure