mirror of
https://ghproxy.net/https://github.com/abhijitb/helix.git
synced 2025-08-28 06:26:00 +08:00
lint fixes
This commit is contained in:
parent
d106c178ac
commit
01a7f967a4
7 changed files with 395 additions and 243 deletions
|
@ -1,13 +1,26 @@
|
|||
<?php
|
||||
add_action('rest_api_init', function () {
|
||||
register_rest_route('helix/v1', '/settings', [
|
||||
'methods' => 'GET',
|
||||
'permission_callback' => '__return_true',
|
||||
'callback' => function () {
|
||||
return [
|
||||
'siteTitle' => get_option('blogname'),
|
||||
'language' => get_option('WPLANG'),
|
||||
];
|
||||
}
|
||||
]);
|
||||
});
|
||||
/**
|
||||
* Registers REST API routes for Helix.
|
||||
*
|
||||
* @package Helix
|
||||
*/
|
||||
|
||||
add_action(
|
||||
'rest_api_init',
|
||||
function () {
|
||||
register_rest_route(
|
||||
'helix/v1',
|
||||
'/settings',
|
||||
array(
|
||||
'methods' => 'GET',
|
||||
'permission_callback' => '__return_true',
|
||||
'callback' => function () {
|
||||
return array(
|
||||
'siteTitle' => get_option( 'blogname' ),
|
||||
'language' => get_option( 'WPLANG' ),
|
||||
);
|
||||
},
|
||||
)
|
||||
);
|
||||
}
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue