“Add Twitter card meta data” is enabled but the “twitter:image” meta tag does not get output when viewing an attachment page. If a default image is set site wide then this default image always displays instead of the preferred attachment image.
I think I’ve narrowed the problem down to the image function in class-twitter.php. Basically the first if statament doesn’t account for the page being an attachment.
Replacing the line: if ( function_exists( 'has_post_thumbnail' ) && has_post_thumbnail( $post->ID ) ) {
with: if ( (function_exists( 'has_post_thumbnail' ) && has_post_thumbnail( $post->ID )) || is_attachment()) {
seem to fix the problem but not sure if it’s the best solution.