From 5749f8cfca2c5612581459f952d44e04db1f39c1 Mon Sep 17 00:00:00 2001 From: Utkarsh Patel Date: Wed, 22 Dec 2021 14:18:40 +0530 Subject: [PATCH] Update regex to handle 404 template slug :bug: --- .../wordpress-5.9/class-gutenberg-rest-templates-controller.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/compat/wordpress-5.9/class-gutenberg-rest-templates-controller.php b/lib/compat/wordpress-5.9/class-gutenberg-rest-templates-controller.php index 21b2a4d3a0ded6..085acca1d036d6 100644 --- a/lib/compat/wordpress-5.9/class-gutenberg-rest-templates-controller.php +++ b/lib/compat/wordpress-5.9/class-gutenberg-rest-templates-controller.php @@ -600,7 +600,7 @@ public function get_item_schema() { 'context' => array( 'embed', 'view', 'edit' ), 'required' => true, 'minLength' => 1, - 'pattern' => '[a-zA-Z_\-]+', + 'pattern' => '[a-zA-Z0-9_\-]+', ), 'theme' => array( 'description' => __( 'Theme identifier for the template.', 'gutenberg' ),