Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/experimental'
Browse files Browse the repository at this point in the history
  • Loading branch information
prowebat committed Dec 16, 2023
2 parents 268065e + 75841b2 commit e4315a8
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
22 changes: 11 additions & 11 deletions externallib.php
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ public static function add_item_parameters() {
'type' => new external_value(PARAM_TEXT, 'type of item (note,file,link)', VALUE_DEFAULT, ''),
'fileitemid' => new external_value(PARAM_INT, 'itemid for draft-area files; for "private" files is ignored',
VALUE_DEFAULT, null),
'filename' => new external_value (PARAM_TEXT, 'deprecated (was used for upload into private files)', VALUE_DEFAULT,
'filename' => new external_value(PARAM_TEXT, 'deprecated (was used for upload into private files)', VALUE_DEFAULT,
''),
]);
}
Expand Down Expand Up @@ -362,7 +362,7 @@ public static function update_item_parameters() {
'fileitemid' => new external_value(PARAM_INT,
'itemid for draft-area files; for "private" files is ignored, use \'0\' to delete the file', VALUE_DEFAULT,
null),
'filename' => new external_value (PARAM_TEXT, 'deprecated (was used for upload into private files)', VALUE_DEFAULT,
'filename' => new external_value(PARAM_TEXT, 'deprecated (was used for upload into private files)', VALUE_DEFAULT,
''),
]);
}
Expand Down Expand Up @@ -1636,7 +1636,7 @@ public static function export_file_to_externalportfolio_returns() {
}

public static function get_user_information_parameters() {
return new external_function_parameters (array());
return new external_function_parameters(array());
}

/**
Expand All @@ -1653,7 +1653,7 @@ public static function get_user_information() {
}

public static function get_user_information_returns() {
return new external_single_structure (array(
return new external_single_structure(array(
'id' => new external_value(PARAM_INT, 'ID of the user'),
'username' => new external_value(PARAM_RAW, 'The username', VALUE_OPTIONAL),
'firstname' => new external_value(PARAM_NOTAGS, 'The first name(s) of the user', VALUE_OPTIONAL),
Expand All @@ -1673,9 +1673,9 @@ public static function get_user_information_returns() {

public static function login_parameters() {
return new external_function_parameters(array(
'app' => new external_value (PARAM_INT, 'app accessing this service (eg. dakora)'),
'app_version' => new external_value (PARAM_INT, 'version of the app (eg. 4.6.0)'),
'services' => new external_value (PARAM_INT, 'wanted webservice tokens (eg. exacomp,exaport)', VALUE_DEFAULT,
'app' => new external_value(PARAM_INT, 'app accessing this service (eg. dakora)'),
'app_version' => new external_value(PARAM_INT, 'version of the app (eg. 4.6.0)'),
'services' => new external_value(PARAM_INT, 'wanted webservice tokens (eg. exacomp,exaport)', VALUE_DEFAULT,
'moodle_mobile_app,exaportservices'),
));
}
Expand All @@ -1686,12 +1686,12 @@ public static function login_parameters() {
* @return external_multiple_structure
*/
public static function login_returns() {
return new external_single_structure ([
return new external_single_structure([
'user' => static::get_user_information_returns(),
'config' => new external_single_structure([]),
'tokens' => new external_multiple_structure (new external_single_structure ([
'service' => new external_value (PARAM_TEXT, 'name of service'),
'token' => new external_value (PARAM_TEXT, 'token of the service'),
'tokens' => new external_multiple_structure(new external_single_structure([
'service' => new external_value(PARAM_TEXT, 'name of service'),
'token' => new external_value(PARAM_TEXT, 'token of the service'),
]), 'requested tokens'),
]);
}
Expand Down
2 changes: 1 addition & 1 deletion shared_view.php
Original file line number Diff line number Diff line change
Expand Up @@ -1180,8 +1180,8 @@ function pdf_view($view, $colslayout, $data_for_pdf, $pdf_settings) {
$pdf_content .= '</body>' . "\r\n";
$pdf_content .= '</html>';

$pdf_content = prependHtmlContentToPdf($pdf_content, $view);
}
$pdf_content = prependHtmlContentToPdf($pdf_content, $view);

// Output for debugging.
// echo '<textarea>';
Expand Down

0 comments on commit e4315a8

Please sign in to comment.