Home

>

Tools

>

Ghost

>

Releases

>

5.22.9

Ghost Release: 5.22.9

Tag Name: v5.22.9

Release Date: 11/8/2022

Ghost LogoGhost

Open-source publishing platform specifically designed for professional bloggers and publications. Focuses on clean, minimalist writing and publishing experience.

TL;DR

Ghost v5.22.9 fixes a critical bug in the Stripe Checkout flow where deleted Stripe objects were not being properly handled. This patch ensures that the payment system gracefully handles cases where Stripe objects no longer exist, preventing checkout failures. The update also optimizes Stripe API usage by improving how price data is queried.

Highlight of the Release

    • Fixed bug in Stripe Checkout flow to handle deleted Stripe objects gracefully
    • Added comprehensive error handling for all Stripe API read requests
    • Optimized Stripe Price queries to reduce API calls
    • Included automated tests to verify the fix

Migration Guide

No migration steps are required for this release. The update can be applied without any additional configuration changes.

Upgrade Recommendations

This update is highly recommended for all Ghost installations that use Stripe for payments and subscriptions. The bug fix addresses a potential issue that could cause checkout failures when Stripe objects have been deleted, which might impact revenue collection.

The update is backward compatible and requires no configuration changes, making it a low-risk upgrade that improves system reliability.

Bug Fixes

Stripe Checkout Flow Improvements

This release fixes an important bug in the Stripe Checkout flow where the system was checking if Stripe objects were active but not verifying if they still existed in Stripe's database. When objects had been deleted from Stripe, this would cause checkout failures.

The fix adds proper error handling to all read requests to the Stripe API within the payment link flow, allowing the system to gracefully handle cases where Stripe objects have been deleted. This prevents unexpected errors during the checkout process.

Additionally, the query mechanism for finding Stripe Prices has been improved, resulting in fewer API requests to Stripe when validating price data.

New Features

No new features were added in this release. This is a bug fix release focused on improving the reliability of the existing Stripe Checkout flow.

Security Updates

No specific security fixes were included in this release.

Performance Improvements

Optimized Stripe API Usage

The release includes an optimization for Stripe Price queries that reduces the number of API calls made to Stripe. This improvement helps:

  • Lower the API request volume to Stripe
  • Reduce latency in checkout flows
  • Improve overall performance when processing payments

By making fewer validation requests to check if prices are valid, the system operates more efficiently while maintaining the same level of reliability.

Impact Summary

This release addresses a specific but important edge case in the Stripe Checkout flow where deleted Stripe objects were not being properly handled. The impact is primarily on the reliability of payment processing, with sites that use Stripe for memberships and subscriptions benefiting from more robust error handling.

The changes are focused on defensive programming - adding proper checks and error handling to ensure the system gracefully handles situations where expected Stripe objects no longer exist. This prevents unexpected errors during checkout that could potentially lead to lost revenue.

Additionally, the optimization of Stripe Price queries reduces the number of API calls to Stripe, which improves performance and helps stay within API rate limits.

Overall, this is a targeted maintenance release that improves system reliability without introducing any breaking changes or requiring configuration updates.

Full Release Notes

  • 🐛 Handled deleted Stripe objects in the Stripe Checkout flow - Fabien "egg" O'Carroll

View the changelog for full details: v5.22.8...v5.22.9

🪄 Love open source? We're hiring JavaScript Engineers to work on Ghost full-time

Statistics:

File Changed9
Line Additions289
Line Deletions63
Line Changes352
Total Commits2

User Affected:

  • More reliable payment processing for memberships and subscriptions
  • Fewer failed checkouts due to deleted Stripe objects
  • Reduced likelihood of payment errors affecting revenue

Contributors:

allouisgithub-actions[bot]