mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FIX: If there's an error downloading, don't raise it
This commit is contained in:
@@ -82,7 +82,7 @@ class UserAvatar < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
rescue Net::ReadTimeout
|
rescue Net::ReadTimeout, OpenURI::HTTPError
|
||||||
# skip saving, we are not connected to the net
|
# skip saving, we are not connected to the net
|
||||||
ensure
|
ensure
|
||||||
tempfile.close! if tempfile && tempfile.respond_to?(:close!)
|
tempfile.close! if tempfile && tempfile.respond_to?(:close!)
|
||||||
|
|||||||
Reference in New Issue
Block a user