mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Checking size of some gifs throws a Zlib::BufError. Tolerate it until we can figure out why.
This commit is contained in:
parent
2e8e4b7c6e
commit
631ed3df58
@ -161,6 +161,9 @@ class CookedPostProcessor
|
||||
# return nil when it's an external image *and* crawling is disabled
|
||||
return nil unless SiteSetting.crawl_images? || uri[0] == "/"
|
||||
@size_cache[uri] ||= FastImage.size(uri)
|
||||
rescue Zlib::BufError
|
||||
# FastImage.size raises BufError for some gifs
|
||||
return nil
|
||||
end
|
||||
|
||||
def get_image_uri(url)
|
||||
|
Loading…
Reference in New Issue
Block a user