diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-controller.php
index 5dda1a9360..f5fd74afcc 100644
a
|
b
|
class WP_REST_Global_Styles_Controller extends WP_REST_Controller { |
41 | 41 | // List themes global styles. |
42 | 42 | register_rest_route( |
43 | 43 | $this->namespace, |
44 | | '/' . $this->rest_base . '/themes/(?P<stylesheet>[^.\/]+(?:\/[^.\/]+)?)', |
| 44 | '/' . $this->rest_base . '/themes/(?P<stylesheet>[\/\w\.-]+)', |
45 | 45 | array( |
46 | 46 | array( |
47 | 47 | 'methods' => WP_REST_Server::READABLE, |
… |
… |
class WP_REST_Global_Styles_Controller extends WP_REST_Controller { |
60 | 60 | // Lists/updates a single gloval style variation based on the given id. |
61 | 61 | register_rest_route( |
62 | 62 | $this->namespace, |
63 | | '/' . $this->rest_base . '/(?P<id>[\/\w-]+)', |
| 63 | '/' . $this->rest_base . '/(?P<id>[\/\w\.-]+)', |
64 | 64 | array( |
65 | 65 | array( |
66 | 66 | 'methods' => WP_REST_Server::READABLE, |
diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php
index 75411b107f..e6648bb84a 100644
a
|
b
|
class WP_REST_Templates_Controller extends WP_REST_Controller { |
68 | 68 | // Lists/updates a single template based on the given id. |
69 | 69 | register_rest_route( |
70 | 70 | $this->namespace, |
71 | | '/' . $this->rest_base . '/(?P<id>[\/\w-]+)', |
| 71 | '/' . $this->rest_base . '/(?P<id>[\/\w\.-]+)', |
72 | 72 | array( |
73 | 73 | 'args' => array( |
74 | 74 | 'id' => array( |