Getting the following ‘doing it wrong’ error:
“The REST API route definition for msl/v1/sites is missing the required permission_callback argument. For REST API routes that are intended to be public, use __return_true as the permission callback.”
Fixed it with these changes in multisite-superlist.php mssl_register_sites() function starting on line 119:
array(
'methods' => 'GET',
'callback' => 'mssl_api_custom_route_sites',
'permission_callback' => function($request){
return is_super_admin( get_current_user_id() ) ? '__return_true' : '__return_false';
},
)
Thanks for the awesome plugin! Want to see it stay ahead of WP Core changes like this 😉