mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 21:49:15 +01:00
MDL-78459 tool_mobile: use site context in mobile manifest file.
Prevents debugging notices when the site shortname is formatted in the response data.
This commit is contained in:
parent
1b1a15a308
commit
3af9bdfa7e
@ -30,7 +30,6 @@
|
||||
define('NO_DEBUG_DISPLAY', true);
|
||||
|
||||
require_once(__DIR__ . '/../../../config.php');
|
||||
use tool_mobile\api;
|
||||
|
||||
header('Content-Type: application/json; charset: utf-8');
|
||||
|
||||
@ -40,7 +39,9 @@ if (!empty($CFG->enablemobilewebservice) && !empty($mobilesettings->enablesmarta
|
||||
!empty($mobilesettings->androidappid)) {
|
||||
|
||||
$manifest = new StdClass;
|
||||
$manifest->short_name = format_string($SITE->shortname);
|
||||
$manifest->short_name = format_string($SITE->shortname, true, [
|
||||
'context' => \core\context\system::instance(),
|
||||
]);
|
||||
$manifest->prefer_related_applications = true;
|
||||
$manifest->icons = [(object)
|
||||
[
|
||||
|
Loading…
x
Reference in New Issue
Block a user