Opened 6 months ago

Closed 6 months ago

#22596 closed defect (bug) (fixed)

Only show editor button when it's an image

Reported by: markoheijnen Owned by: ryan
Priority: normal Milestone: 3.5
Component: Media Version: 3.5
Severity: normal Keywords: has-patch commit
Cc:

Description

Imagick supports a bunch of mime types to be edited but WordPress itself doesn't allow that.

So when you upload a PDF you can press the 'Edit Image' button but get an error instead: "Image data does not exist. Please re-upload the image.".

Attachments (1)

22596.diff (1.4 KB) - added by markoheijnen 6 months ago.
Add wp_attachment_is_image() checks

Download all attachments as: .zip

Change History (4)

Add wp_attachment_is_image() checks

Tested; looks good, thanks!

  • Keywords commit added
  • Owner set to ryan
  • Resolution set to fixed
  • Status changed from new to closed

In 22867:

Only show the image edit button for image attachments. Props markoheijnen. fixes #22596

Note: See TracTickets for help on using tickets.