Fix nil error in focal_point? (#6537)

main
Eugen Rochko 7 years ago committed by GitHub
parent 5f3bee345d
commit b8535ad4df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -19,7 +19,7 @@ class ActivityPub::ImageSerializer < ActiveModel::Serializer
end end
def focal_point? def focal_point?
object.respond_to?(:meta) && object.meta['focus'].is_a?(Hash) object.respond_to?(:meta) && object.meta.is_a?(Hash) && object.meta['focus'].is_a?(Hash)
end end
def focal_point def focal_point

Loading…
Cancel
Save