Skip to content

Fix empty theme variation names - #904

Open
elphizu wants to merge 1 commit into
WordPress:trunkfrom
elphizu:fix/validate-variation-name
Open

elphizu wants to merge 1 commit into
WordPress:trunkfrom
elphizu:fix/validate-variation-name

Conversation

@elphizu

@elphizu elphizu commented Nov 6, 2026

Copy link
Copy Markdown

Creating a variation with an empty name currently reports success and writes styles/.json with an empty title.

This change disables the Create button for empty or whitespace-only names and adds server-side PHP validation to reject empty names or slugs before creating directories or writing files.

Fixes #903

Use of AI Tools

AI assistance: Yes
Tool(s): OpenAI Codex
Used for: Investigating the issue, implementing validation, adding regression tests, and drafting the PR description, which I reviewed and edited.

@elphizu
elphizu marked this pull request as ready for review November 6, 2026 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Empty variation name reports success and creates styles/.json

1 participant