From 7977e842fb051239bb50c68af02540e010a14d22 Mon Sep 17 00:00:00 2001 From: August Miller Date: Tue, 12 Nov 2024 16:21:13 -0800 Subject: [PATCH] `permission_callback` is required for `register_rest_route()` MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This route seems OK to make public—this isn't a valid solution for most other things we're doing! --- plugins/wp-import-helper.php | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/wp-import-helper.php b/plugins/wp-import-helper.php index 33db29a..13290c0 100644 --- a/plugins/wp-import-helper.php +++ b/plugins/wp-import-helper.php @@ -41,6 +41,7 @@ 'callback' => fn() => [ 'pong' => true, ], + 'permission_callback' => '__return_true', ]); register_rest_route('craftcms/v1', 'info', [