@@ 36-41 (lines=6) @@ | ||
33 | public function fuzzy_image_meta() { |
|
34 | $meta = wp_get_attachment_metadata( $this->image->ID ); |
|
35 | $img_meta = ( ! empty( $meta['image_meta'] ) ) ? (array) $meta['image_meta'] : array(); |
|
36 | if ( ! empty( $img_meta ) ) { |
|
37 | foreach ( $img_meta as $k => $v ) { |
|
38 | if ( 'latitude' == $k || 'longitude' == $k ) |
|
39 | unset( $img_meta[$k] ); |
|
40 | } |
|
41 | } |
|
42 | ||
43 | return $img_meta; |
|
44 | } |
@@ 454-459 (lines=6) @@ | ||
451 | $attachment_title = wptexturize( $attachment->post_title ); |
|
452 | $attachment_desc = wpautop( wptexturize( $attachment->post_content ) ); |
|
453 | // Not yet providing geo-data, need to "fuzzify" for privacy |
|
454 | if ( ! empty( $img_meta ) ) { |
|
455 | foreach ( $img_meta as $k => $v ) { |
|
456 | if ( 'latitude' == $k || 'longitude' == $k ) |
|
457 | unset( $img_meta[$k] ); |
|
458 | } |
|
459 | } |
|
460 | ||
461 | // See https://github.com/Automattic/jetpack/issues/2765 |
|
462 | if ( isset( $img_meta['keywords'] ) ) { |