597 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7)
361dfe8145
MDL-75952 general: Since php81, refection->setAccessible() is no-op
Refereces:
- https://wiki.php.net/rfc/make-reflection-setaccessible-no-op
- https://www.php.net/manual/en/reflectionproperty.setaccessible.php
- https://www.php.net/manual/en/reflectionmethod.setaccessible.php

As of PHP 8.1.0, calling this method has no effect; all methods are
invokable by default. So, let's remove all uses from core, they are
no-op.
2024-03-10 21:15:00 +01:00
Eloy Lafuente (stronk7)
ba1f804ffa
MDL-65292 style: Fix all function declarations white space
This has been generated running the following Sniffs, all
them part of the Moodle's CodeSniffer standard:
- PSR12.Functions.ReturnTypeDeclaration
- PSR12.Functions.NullableTypeDeclaration
- moodle.Methods.MethodDeclarationSpacing
- Squiz.Whitespace.ScopeKeywordSpacing

All them are, exclusively, about correct spacing, so the changes
are, all them, only white space changes.

Only exceptions to the above are 3 changes what were setting the
return type in a new line, and, when that happens, the closing
parenthesis (bracket) has to go to the same line than the colon.
2024-02-28 23:33:26 +01:00
Huong Nguyen
b32407f1e9 Merge branch 'MDL-80724-master' of https://github.com/jleyva/moodle 2024-02-13 10:10:58 +07:00
Jun Pataleta
245edd9a11
Merge branch 'MDL-73008-master' of https://github.com/jleyva/moodle 2024-01-29 14:42:08 +08:00
Juan Leyva
94bc97a8b2 MDL-80724 webservice: Return whether competencies are enabled 2024-01-26 13:56:23 +01:00
Sara Arjona
8b36abdb9d
Merge branch 'MDL-80259-main' of https://github.com/roland04/moodle 2024-01-24 09:16:12 +01:00
Mikel Martín
a198884333 MDL-80259 theme_boost: Refactor badge helper classes for Bootstrap 5 2024-01-23 08:27:23 +01:00
Jun Pataleta
154774c061
MDL-80119 webservice: Fix typo for generated webservices_* classes 2024-01-23 14:17:22 +08:00
Juan Leyva
f40c196e51 MDL-73008 ws: Return current policy acceptance status 2023-12-05 10:12:56 +01:00
Andrew Nicols
53416b1c1e
MDL-80119 core: Address issues with saner inc/dec operators 2023-11-15 09:16:13 +08:00
Jun Pataleta
94bc2cd38b
MDL-79551 versions: bump all versions and requires near release 2023-10-04 13:57:17 +08:00
Juan Leyva
325ef8095e MDL-56020 search: Return global search settings 2023-08-28 15:48:18 +02:00
Paul Holden
ad06206508
MDL-78503 webservice: include token last access time in reports. 2023-07-18 09:19:24 +01:00
Paul Holden
686b054b78
MDL-78637 webservice: display token info after user performs reset. 2023-07-03 14:26:38 +01:00
Ilya Tregubov
ab6dc892e4
Merge branch 'MDL-76656-master' of https://github.com/meirzamoodle/moodle 2023-06-28 18:08:21 +08:00
meirzamoodle
f69a420be1 MDL-76656 webservice: generated token can only read once
Generated tokens should only read once.
Therefore removing the token column at the table view of the manage tokens page and the user's page.
The token should not be able to search.
2023-06-28 09:27:31 +07:00
Andrew Nicols
346d508950
Merge branch 'MDL-77799-master' of https://github.com/sammarshallou/moodle 2023-06-08 11:20:26 +08:00
sam marshall
6f48fe50a2 MDL-77799 webservice_rest: unhandled exception should go in server log 2023-06-07 10:02:41 +01:00
Paul Holden
9990a740bf
MDL-78352 webservice: use default user context page heading. 2023-05-26 12:25:38 +01:00
Paul Holden
373c163f74
MDL-78339 webservice: correctly namespace external API. 2023-05-24 09:36:23 +01:00
Meirza
4fbb4f552f MDL-77350 webservice: Added class properties that are not declared
In PHP 8.2 and later, setting a value to an undeclared class property is
deprecated and emits a deprecation notice.
So we need to add missing class properties that still need to be declared.
2023-05-16 00:33:19 +07:00
Jake Dallimore
bdee325701 MDL-78094 webservice_soap: fix use of core_external in locallib 2023-05-03 09:41:50 +08:00
Jun Pataleta
8dd488cb5b Merge branch 'MDL-77989-master' of https://github.com/andrewnicols/moodle 2023-04-21 13:44:51 +08:00
Andrew Nicols
fcba0cb379 MDL-77989 core: Fix uses of legacy external API 2023-04-21 13:33:56 +08:00
Dan Marsden
9d162d1b8a MDL-77989 webservices: fix unit test error with xmlize_result 2023-04-21 09:31:57 +08:00
Eloy Lafuente (stronk7)
061c9d7ba0 MDL-77940 versions: bump all versions and requires near release
version = 2023042400 release version
requires= 2023041800 current rc1 version
2023-04-18 18:08:09 +02:00
Sara Arjona
9ce4fb65fd Merge branch 'MDL-77164-master' of https://github.com/marinaglancy/moodle 2023-04-13 14:00:18 +02:00
Marina Glancy
8fc1486d36 MDL-77164 various: fix incorrect phpdocs 2023-04-13 11:35:06 +01:00
Sara Arjona
cdeec59377 Merge branch 'MDL-76792-master' of https://github.com/jleyva/moodle 2023-04-11 09:13:08 +02:00
Juan Leyva
b540a59e55 MDL-76792 webservice: Avoid exception when missing component 2023-03-29 17:28:05 +02:00
Anupama Sarjoshi
23aab0eebf MDL-77406 core: Fix code checker issues 2023-03-28 17:50:03 +01:00
Anupama Sarjoshi
42f4b0a991 MDL-77406 core: Logs to record user file uploaded in draft area 2023-03-28 17:49:54 +01:00
Mathew May
e5ca7766e7 MDL-52805 core: Remove legacy log calls 2023-03-07 13:08:46 +08:00
Jun Pataleta
8c3cb3d17e Merge branch 'MDL-77027-master' of https://github.com/andrewnicols/moodle 2023-01-25 15:33:52 +08:00
Andrew Nicols
a72168741c MDL-77027 webservice: Add missing class requires 2023-01-25 11:14:59 +08:00
Andrew Nicols
5e33d57dbe MDL-76987 webservice: Correct namespace for external_api 2023-01-23 20:37:05 +08:00
Andrew Nicols
a3cc26f8bb MDL-76583 core: Update uses of external_* classes 2023-01-19 07:34:09 +08:00
Andrew Nicols
fa676b4776 MDL-76583 core_external: Implement Privacy API for core_external
AMOS BEGIN
 MOV [privacy:metadata:serviceusers,core_webservice],[privacy:metadata:serviceusers,core_external]
 MOV [privacy:metadata:serviceusers:iprestriction,core_webservice],[privacy:metadata:serviceusers:iprestriction,core_external]
 MOV [privacy:metadata:serviceusers:timecreated,core_webservice],[privacy:metadata:serviceusers:timecreated,core_external]
 MOV [privacy:metadata:serviceusers:userid,core_webservice],[privacy:metadata:serviceusers:userid,core_external]
 MOV [privacy:metadata:serviceusers:validuntil,core_webservice],[privacy:metadata:serviceusers:validuntil,core_external]
 MOV [privacy:metadata:tokens,core_webservice],[privacy:metadata:tokens,core_external]
 MOV [privacy:metadata:tokens:creatorid,core_webservice],[privacy:metadata:tokens:creatorid,core_external]
 MOV [privacy:metadata:tokens:iprestriction,core_webservice],[privacy:metadata:tokens:iprestriction,core_external]
 MOV [privacy:metadata:tokens:lastaccess,core_webservice],[privacy:metadata:tokens:lastaccess,core_external]
 MOV [privacy:metadata:tokens:privatetoken,core_webservice],[privacy:metadata:tokens:privatetoken,core_external]
 MOV [privacy:metadata:tokens:timecreated,core_webservice],[privacy:metadata:tokens:timecreated,core_external]
 MOV [privacy:metadata:tokens:token,core_webservice],[privacy:metadata:tokens:token,core_external]
 MOV [privacy:metadata:tokens:tokentype,core_webservice],[privacy:metadata:tokens:tokentype,core_external]
 MOV [privacy:metadata:tokens:userid,core_webservice],[privacy:metadata:tokens:userid,core_external]
 MOV [privacy:metadata:tokens:validuntil,core_webservice],[privacy:metadata:tokens:validuntil,core_external]
 MOV [privacy:request:notexportedsecurity,core_webservice],[privacy:request:notexportedsecurity,core_external]
AMOS END
2023-01-19 07:33:35 +08:00
Ilya Tregubov
9ba9589f09 Merge branch 'MDL-74853-master' of https://github.com/marinaglancy/moodle 2022-12-01 08:55:34 +03:00
Marina Glancy
a800e7e62f MDL-74853 various: add second parameter to htmlentities functions
Default value of the $flag argument changed in PHP 8.1 from ENT_COMPAT to ENT_QUOTES | ENT_SUBSTITUTE
To ensure consistent behavior across different PHP version the second parameter is now required for the functions:
htmlspecialchars(), htmlentities(), htmlspecialchars_decode(), html_entity_decode() and get_html_translation_table()
2022-11-28 16:12:20 +01:00
Paul Holden
f8ef28f9a6 MDL-76284 webservice: early exit if no users for missing capabilities. 2022-11-28 11:52:45 +00:00
Jun Pataleta
00bae8b8a4 MDL-76403 versions: bump all versions and requires near release 2022-11-23 09:45:23 +08:00
Eloy Lafuente (stronk7)
e7d3e042fc MDL-76052 webservice_xmlrpc: Annotate some wrong plugin uses
It has been detected that there are various uses of the plugins
breaking the inter-communication principles, with core_webservice
implementing functionality plugin-dependent that should belong
to the plugins.

Because of that, https://tracker.moodle.org/browse/MDL-76078 has
been created and we have added some TODO/@todo comments in core
pointing to that issue, for further analysis and fixes there.
2022-11-04 16:49:57 +01:00
Eloy Lafuente (stronk7)
df227f3819 MDL-76052 webservice_xmlrpc: Remove it completely from core
Normal removal procedure:
  - Remove the plugin completely from core.
  - Document it in the webservices upgrade.txt file.
  - Add a core upgrade step to proceed to remove any configuration
    if the plugin has not been re-installed manually.

Plus:
  - Remove a few remaining uses in the hub/sites registration scripts,
    that were moved from xmlrpc to hand.made rest calls by MDL-31436
    (Moodle 3.4.1 and up) and never removed then.
  - Remove the php-xmlrpc extension as a recommendation in composer.
  - Remove "xmlrpc" from various comments, trivial cleanup.

Note:
  - While working on this MDL-76078 has been created about to
    fix a serious design problem detected (it does not affect
    functionality). That's out from this issue scope.
2022-11-04 16:49:52 +01:00
Víctor Déniz
ad3ba9d0b7 Merge branch 'MDL-74827-master' of https://github.com/rmady/moodle 2022-07-21 00:12:23 +01:00
Sujith Haridasan
73d604369d MDL-71062 core: Step 1 deprecation of print_error function 2022-07-13 08:20:54 +05:30
Rodrigo Mady da Silva
892047d3c8 MDL-74827 core_webservice: Add enablecustomreports in WS get_site_info 2022-06-23 12:00:43 -03:00
Marina Glancy
e3bd0f7348 MDL-29717 core_webservice: Display deprecated badge in API docs 2022-06-03 16:17:47 +02:00
Dmitrii Metelkin
a6cad23b1a MDL-73431 enrol: Introduce a sync interval 2022-05-30 15:58:22 +10:00
Eloy Lafuente (stronk7)
caf55abf17 MDL-74413 phpunit: Move more tests to use correct names and namespaces
Applied the following changes to various testcase classes:

- Namespaced with component[\level2-API]
- Moved to level2-API subdirectory when required.
- Fixed incorrect use statements with leading backslash.
- Remove file phpdoc block
- Remove MOODLE_INTERNAL if not needed.
- Changed code to point to global scope when needed.
- Fix some relative paths and comments here and there.
- All them passing individually.
- Complete runs passing too.

Special mention to:

- Moved to the level2 "privacy" namespace:
  - \mod_assign\privacy\feedback_legacy_polyfill_test
  - \mod_assign\privacy\submission_legacy_polyfill_test

- Moved to the level2 "task" namespace:
  - \core_message\task\migrate_message_data_test
  - \ltiservice_gradebookservices\task\cleanup_test
  - \message_email\task\send_email_test
  - \mod_lti\task\clean_access_tokens_test
  - \mod_workshop\task\cron_task_test

- Moved to the level2 "event" namespace:
  - \core_h5p\event\deleted_test
  - \core_h5p\event\viewed_test

- Renamed to a better name:
  - backup_forum_activity_task_test.php (missing "task")
2022-05-07 20:32:30 +02:00