Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use wp_unique_id() instead of uniqid() in block_core_gallery_render() #39983

Merged
merged 1 commit into from
Apr 3, 2022

Conversation

westonruter
Copy link
Member

This is amends #38164.

Fixes #38889.

Previously #38891.

What?

Why?

How?

Testing Instructions

Screenshots or screencast

Copy link
Member

@gziolo gziolo left a comment

Choose a reason for hiding this comment

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

Good catch 👍

Do you think it is something we could programmatically enforce in the future?

@gziolo gziolo added [Type] Code Quality Issues or PRs that relate to code quality [Block] Gallery Affects the Gallery Block - used to display groups of images labels Apr 2, 2022
@Mamaduka Mamaduka merged commit 090ec5a into trunk Apr 3, 2022
@Mamaduka Mamaduka deleted the update/unique-id-function-in-gallery-block branch April 3, 2022 07:02
@github-actions github-actions bot added this to the Gutenberg 13.0 milestone Apr 3, 2022
@westonruter
Copy link
Member Author

Do you think it is something we could programmatically enforce in the future?

A custom PHPCS ruleset would do it, although that may be overkill.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Gallery Affects the Gallery Block - used to display groups of images [Type] Code Quality Issues or PRs that relate to code quality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use of uniqid() in generated CSS class names breaks ability to cache parsed CSS
3 participants