Skip to content

Fixed broken preview for last optimized image#1063

Merged
vytisbulkevicius merged 1 commit into
developmentfrom
bugfix/1054
May 19, 2026
Merged

Fixed broken preview for last optimized image#1063
vytisbulkevicius merged 1 commit into
developmentfrom
bugfix/1054

Conversation

@girishpanchal30

Copy link
Copy Markdown
Contributor

All Submissions:

Changes proposed in this Pull Request:

As we get the S3 resource ID capitalized, we need to convert it to lowercase.

Closes #1054

Other information:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes, as applicable?
  • Have you successfully ran tests with your changes locally?

@pirate-bot

Copy link
Copy Markdown
Collaborator

Plugin build for 287dbdf is ready 🛎️!

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the broken “last optimized image” preview in the Optimole WP admin UI by normalizing the cloud/offload resource identifier coming from the stats API before generating the preview URL.

Changes:

  • Lowercase the key value returned by the optimized-images stats endpoint before passing it to get_media_optimized_url(), preventing mismatches when the ID is returned capitalized.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@vytisbulkevicius vytisbulkevicius merged commit 19b03ab into development May 19, 2026
16 checks passed
@vytisbulkevicius vytisbulkevicius deleted the bugfix/1054 branch May 19, 2026 09:05
@pirate-bot

Copy link
Copy Markdown
Collaborator

🎉 This PR is included in version 4.2.6 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@pirate-bot pirate-bot added the released Indicate that an issue has been resolved and released in a particular version of the product. label May 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released Indicate that an issue has been resolved and released in a particular version of the product.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants