Skip to content

Commit 2cb8b64

Browse files
committed
Fix PHP documentation errors
1 parent 9060871 commit 2cb8b64

File tree

6 files changed

+22
-22
lines changed

6 files changed

+22
-22
lines changed

classes/local/clients/user_folder_access.php

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -123,8 +123,8 @@ protected function get_user_oauth_client($oauthloginreturnurl) {
123123
/**
124124
* A method, which attempts to rename a given, privately shared, folder.
125125
*
126-
* @param $pathtofolder string path, which leads to the folder that needs to be renamed.
127-
* @param $newname string the name which needs to be set instead of the old.
126+
* @param string $pathtofolder path, which leads to the folder that needs to be renamed.
127+
* @param string $newname the name which needs to be set instead of the old.
128128
* @return array contains status (true means success, false failure) and content (generated
129129
* link or error message) of the result.
130130
*/
@@ -196,10 +196,10 @@ public function check_login(): bool {
196196
* database table. If the specific record already exists, it gets updated in the concerning field. Otherwise,
197197
* a new record is inserted into the table.
198198
*
199-
* @param $cmid int ID of the course module. Needed to specify the concrete activity instance.
200-
* @param $groupid int the group ID to specify one particular folder.
201-
* @param $userid string ID of the user, which the value needs to be set for.
202-
* @param $value string the specific value, which needs to be set or updated.
199+
* @param int $cmid ID of the course module. Needed to specify the concrete activity instance.
200+
* @param int $groupid the group ID to specify one particular folder.
201+
* @param string $userid ID of the user, which the value needs to be set for.
202+
* @param string $value the specific value, which needs to be set or updated.
203203
*/
204204
public function store_link($cmid, $groupid, $userid, $value) {
205205
// TODO use persistent API instead.
@@ -231,9 +231,9 @@ public function store_link($cmid, $groupid, $userid, $value) {
231231
* database table. It is used to get a stored folder name or link for a specific user and course
232232
* module.
233233
*
234-
* @param $cmid int the course module ID. Needed to specify the concrete activity instance.
235-
* @param $groupid int the group ID to specify one particular folder.
236-
* @param $userid string ID of the user, which the value needs to be gotten for.
234+
* @param int $cmid the course module ID. Needed to specify the concrete activity instance.
235+
* @param int $groupid the group ID to specify one particular folder.
236+
* @param string $userid ID of the user, which the value needs to be gotten for.
237237
* @return object|false
238238
*/
239239
public function get_link($cmid, $groupid, $userid) {

classes/output/renderer.php

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,8 @@ public function render_widget_misconfiguration() {
113113

114114
/**
115115
* Render problem_sharessuppressed notification.
116+
* @param int $sharessuppressed sharesuppressed option
117+
* @return string
116118
*/
117119
public function render_widget_noconnection_suppressed_share(int $sharessuppressed) {
118120
$info = (object)[
@@ -130,7 +132,8 @@ public function render_widget_noconnection_suppressed_share(int $sharessuppresse
130132

131133
/**
132134
* Render the name form.
133-
* @param name_form $form
135+
* @param \stdClass $group group record
136+
* @param name_form $form the name form
134137
*/
135138
public function output_name_form($group, name_form $form) {
136139
if ($group->id !== \mod_collaborativefolders\toolbox::fake_course_group('')->id) {
@@ -152,8 +155,8 @@ public function output_name_form($group, name_form $form) {
152155
* @param stdClass $group Group object containing ID and name
153156
* @param int $cmid Course module ID
154157
* @param string $foldername Chosen (and assumed) name of the folder
155-
* @param string $link Link into ownCloud instance
156-
* @param string $warning (optional) warning message to display beside folder details
158+
* @param string $folderlink Link into ownCloud instance
159+
* @param string|null $warning (optional) warning message to display beside folder details
157160
* @return bool|string rendered template.
158161
*/
159162
public function output_shared_folder($group, $cmid, $foldername, $folderlink, $warning = null) {

classes/view_controller.php

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -176,10 +176,10 @@ private static function get_instance_status($collaborativefolder, \cm_info $cm,
176176
* # Defining a user-local name and generating a share
177177
* # Display the selected name, a link, and a button for problem solving (aka re-share).
178178
*
179-
* @param \cm_info $cmid Course module info
180-
* @param array $folderforms
181-
* @param statusinfo $statusinfo
182-
* @param mod_collaborativefolders\output\renderer $renderer
179+
* @param cm_info $cm Course module info
180+
* @param array $folderforms list of folder forms
181+
* @param statusinfo $statusinfo status information
182+
* @param mod_collaborativefolders\output\renderer $renderer plugin renderer
183183
* @param bool $isteacher true if the viewing user is a teacher
184184
* @param bool $systemclientcanshare true if there is a connected system account that could create a share
185185
* @param user_folder_access $userclient connected client for the current user.
@@ -289,7 +289,6 @@ private static function obtain_folders(statusinfo $statusinfo, \cm_info $cm, boo
289289
* @param \cm_info $cm current coursemodule
290290
* @param user_folder_access $userclient connected client of the user
291291
* @param system_folder_access $systemclient connected system client
292-
* @param int|Name $currentuserid Name of the user that the form will be shared with
293292
* @param \context_module $context context of the current coursemodule
294293
*/
295294
public static function handle_folder_form_submitted(

lib.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@
2929
/**
3030
* Returns the information on whether the module supports a feature.
3131
*
32-
* See {@link plugin_supports()} for more info.
33-
*
3432
* @param string $feature FEATURE_xx constant for requested feature
3533
* @return mixed true if the feature is supported, null if unknown
3634
*/

tests/events_test.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ public function test_link_generated(): void {
116116
/**
117117
* Helper method to fetch the results from a triggered event.
118118
*
119-
* @param $event \core\event\base event, which needs to be triggered.
119+
* @param \core\event\base $event event, which needs to be triggered.
120120
* @return \core\event\base|mixed the caught event data.
121121
*/
122122
protected function get_event_result($event) {

tests/generator/lib.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ public function create_test_issuer(string $name): \core\oauth2\issuer {
4242

4343
/**
4444
* Creates Course, course members, groups and groupings to test the module.
45-
* @param $groupmode
46-
* @param $grouping
45+
* @param int $groupmode the group mode
46+
* @param int $grouping the grouping id
4747
* @return array
4848
* @throws coding_exception
4949
*/

0 commit comments

Comments
 (0)