Browse Source

Rescue all exceptions when downloading docs

Thibaut 11 năm trước cách đây
mục cha
commit
e74369aa41
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      lib/tasks/docs.thor

+ 2 - 2
lib/tasks/docs.thor

@@ -149,8 +149,8 @@ class DocsCLI < Thor
           status = begin
             download_doc(doc)
             'OK'
-          rescue OpenURI::HTTPError => error
-            "FAILED (#{error.message})"
+          rescue => e
+            "FAILED (#{e.class}: #{e.message})"
           end
           puts "(#{i += 1}/#{length}) #{doc.name} #{status}"
         end