CraftCMS v4.2.5 Release Notes

Release Date: 2022-09-20 // 9 days ago
  • ➕ Added

    • ➕ Added craft\helpers\Image::targetDimensions().

    🔄 Changed

    • Edit Asset pages now show the “View” button for all file types, not just images, PDFs, and text files. (#11936)

    ✂ Removed

    • ✂ Removed the Punycode PHP library. (#11948)

    🛠 Fixed

    • 🛠 Fixed a bug where image transforms weren’t always getting applied properly to all animation frames. (#11937)
    • 🛠 Fixed a bug where animated WebP images would lose their animation frames when transformed. (#11937)
    • 🛠 Fixed a bug where image transform dimensions could be calculated incorrectly when upscaleImages was false. (#11837)
    • 🛠 Fixed a bug where the users/send-password-reset-email action wasn’t passing errors back to the template. (#11933)
    • 🛠 Fixed an error that occurred when setting a non-numeric width or height on an image transform. (#11837)
    • 🛠 Fixed a bug where the database connection wasn’t being configured properly when fluent config methods and environment variable overrides were being used in combination. (#11941)
    • 🛠 Fixed a bug where slideouts lost their shadows when focused.
    • 🛠 Fixed a bug where relatedTo* arguments weren’t supported by children fields in GraphQL. (#11918)
    • 🛠 Fixed a bug where Image Editor and slideout action buttons were obstructed when the Debug Toolbar was enabled. (#11965)
    • Fixed an error that occurred when installing Craft when MySQL’s sql_require_primary_key setting was enabled. (#11374)
    • 🛠 Fixed a bug subfolders created by Assets fields could be reported as missing when updating asset indexes, even if they contained assets. (#11949)
    • 🛠 Fixed a PHP error that could occur in a potential race condition when calling craft\helpers\FileHelper::clearDirectory().
    • 🛠 Fixed a bug where Structure section entries that were duplicated via the “Save as a new entry” action on a provisional draft weren’t being placed within the structure properly.
    • 🛠 Fixed a bug where element’s searchScore properties would be set to null when their original score was below 1, rather than rounding to 0 or 1. (#11973)

Previous changes from v4.2.4

  • 🔄 Changed

    • 👍 The “New entry” and “New category” buttons on the Entries and Categories index pages now support Ctrl/Command/middle-clicking to open the edit page in a new window. (#11870)
    • Control panel menus now automatically reposition themselves when the window is resized.
    • 👌 Improved the performance of some element queries on MySQL. (#11825)
    • ⚡️ resave/* commands now have a --touch option. When passed, elements’ dateUpdated timestamps will be updated as they’re resaved. (#11849)
    • Underscores within query param values that begin/end with * are now escaped, so they aren’t treated as wildcard characters by the like condition. (#11898)
    • craft\services\Elements::resaveElements() now has a $touch argument.

    🛠 Fixed

    • 🛠 Fixed an error that could occur when upgrading to Craft 4, if any Matrix blocks contained null sortOrder values. (#11843)
    • 🛠 Fixed a bug where image transform dimensions could be calculated incorrectly when upscaleImages was false. (#11837)
    • 🛠 Fixed an error that occurred when parsing an image transform string that was missing an interlace type. (#11834)
    • 🛠 Fixed a bug where element caches weren’t being invalidated during garbage collection, so hard-deleted elements could appear to still exist.
    • 🛠 Fixed a bug where image transforms were always getting saved with dateIndexed set to null. (#11863)
    • 🛠 Fixed an error that could occur when rendering front-end templates if there was a problem connecting to the database. (#11855)
    • 🛠 Fixed a bug where Edit Asset pages were showing the “View” button for assets in volumes without public URLs. (#11860)
    • 🛠 Fixed a bug where the Assets index page wasn’t handling failed uploads properly. (#11866)
    • 🛠 Fixed a bug where it was possible to save an asset with a focal point outside its cropped area. (#11875)
    • 🛠 Fixed a bug where element index filter HUDs were unresponsive if another one was already active for a different site/source. (#11880)
    • 🛠 Fixed a bug where newly-created subfolders on the Assets index page could appear to have the wrong indentation.
    • 🛠 Fixed a UI bug where renaming a newly-created volume subfolder didn’t appear to have any effect.
    • 🛠 Fixed a bug where empty URL fields would be marked as changed, even when no change was made to them. (#11908)
    • 🛠 Fixed a UI bug where autosuggest menus weren’t getting filtered when first opened for inputs with existing values. (#11896)
    • 🛠 Fixed a bug where Entry Type condition rules weren’t working for conditions that were applied to a single element. (#11914)
    • 🛠 Fixed a bug where Related To condition rules weren’t working for conditions that were applied to a single element, for cross-site relations. (#11892)
    • 🛠 Fixed a bug where form action keyboard shortcuts weren’t available when a custom select menu was focused. (#11919)
    • 🛠 Fixed a bug where transforming an animated GIF into a WebP file would only include the first frame. (#11889)
    • 🛠 Fixed a bug where craft\models\FieldLayout::createFromConfig() was ignoring id, uid, type, and reservedFieldHandles keys, if set. (#11929)

    🔒 Security

    • 🛠 Fixed XSS vulnerabilities.
    • Password inputs no longer temporarily reveal the password when the Alt key is pressed. (#11930)