Completed
Push — 1.10.x ( f316e7...812a9a )
by Julito
47:08 queued 01:58
created
main/inc/lib/sub_language.class.php 1 patch
Doc Comments   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,6 +18,7 @@  discard block
 block discarded – undo
18 18
      * Get all files of lang folder (forum.inc.php,gradebook.inc.php,notebook.inc.php)
19 19
      * @param String The lang path folder  (/var/www/my_lms/main/lang/spanish)
20 20
      * @param bool true if we only want the "subname" trad4all instead of  trad4all.inc.php
21
+     * @param string $path
21 22
      *
22 23
      * @return Array All file of lang folder
23 24
      */
@@ -68,6 +69,7 @@  discard block
 block discarded – undo
68 69
     /**
69 70
      * Get all information of language
70 71
      * @param Integer The parent id(Language father id)
72
+     * @param integer $parent_id
71 73
      * @return Array All information about language
72 74
      */
73 75
     public static function get_all_information_of_language($parent_id)
@@ -86,6 +88,7 @@  discard block
 block discarded – undo
86 88
     /**
87 89
      * Get all information of chamilo file
88 90
      * @param String The chamilo path file (/var/www/chamilo/main/lang/spanish/gradebook.inc.php)
91
+     * @param string $system_path_file
89 92
      * @patam Bool Whether we want to remove the '$' prefix in the results or not
90 93
      * @return Array Contains all information of chamilo file
91 94
      */
@@ -345,7 +348,7 @@  discard block
 block discarded – undo
345 348
     /**
346 349
      * Make available the language
347 350
      * @param Integer The language id
348
-     * @return void
351
+     * @return boolean
349 352
      */
350 353
     public static function make_available_language($language_id)
351 354
     {
Please login to merge, or discard this patch.
main/inc/lib/system/session.class.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -14,6 +14,9 @@
 block discarded – undo
14 14
 class Session implements \ArrayAccess
15 15
 {
16 16
 
17
+    /**
18
+     * @param string $variable
19
+     */
17 20
     static function read($variable, $default = null)
18 21
     {
19 22
         return isset($_SESSION[$variable]) ? $_SESSION[$variable] : $default;
Please login to merge, or discard this patch.
main/inc/lib/system/web/request.class.php 1 patch
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -31,6 +31,10 @@
 block discarded – undo
31 31
         return $method == 'GET';
32 32
     }
33 33
 
34
+    /**
35
+     * @param string $key
36
+     * @param string $default
37
+     */
34 38
     public static function post($key, $default = null)
35 39
     {
36 40
         return isset($_POST[$key]) ? $_POST[$key] : $default;
Please login to merge, or discard this patch.
main/inc/lib/system_announcements.lib.php 1 patch
Doc Comments   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -306,7 +306,7 @@  discard block
 block discarded – undo
306 306
 	 * @param int    Whether the announcement should be visible to anonymous users (1) or not (0)
307 307
 	 * @param string The language for which the announvement should be shown. Leave null for all langages
308 308
 	 * @param int    Whether to send an e-mail to all users (1) or not (0)
309
-	 * @return mixed  insert_id on success, false on failure
309
+	 * @return false|string  insert_id on success, false on failure
310 310
 	 */
311 311
     public static function add_announcement(
312 312
         $title,
@@ -648,6 +648,8 @@  discard block
 block discarded – undo
648 648
 	 * @param	int		Whether to send to all teachers (1) or not (0)
649 649
 	 * @param	int		Whether to send to all students (1) or not (0)
650 650
 	 * @param	string	Language (optional, considered for all languages if left empty)
651
+	 * @param integer|null $teacher
652
+	 * @param integer|null $student
651 653
      * @return  bool    True if the message was sent or there was no destination matching. False on database or e-mail sending error.
652 654
 	 */
653 655
 	public static function send_system_announcement_by_email($title, $content, $teacher, $student, $language = null, $sendEmailTest = false)
Please login to merge, or discard this patch.
main/inc/lib/table_sort.class.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
 	 * @param string $direction The direction to sort (SORT_ASC (default) orSORT_DESC)
81 81
 	 * @param array $column_show The columns that we will show in the table i.e: $column_show = array('1','0','1') we will show the 1st and the 3th column.
82 82
 	 * @param array $column_order Changes how the columns will be sorted ie. $column_order = array('0','3','2','3') The column [1] will be sorted like the column [3]
83
-	 * @param constant $type How should data be sorted (SORT_REGULAR, SORT_NUMERIC, SORT_STRING, SORT_DATE, SORT_IMAGE)
83
+	 * @param integer $type How should data be sorted (SORT_REGULAR, SORT_NUMERIC, SORT_STRING, SORT_DATE, SORT_IMAGE)
84 84
 	 * @return array The sorted dataset
85 85
 	 * @author [email protected]
86 86
 	 */
Please login to merge, or discard this patch.
main/inc/lib/template.lib.php 1 patch
Doc Comments   +2 added lines patch added patch discarded remove patch
@@ -330,6 +330,7 @@  discard block
 block discarded – undo
330 330
     /**
331 331
      * Sets the footer visibility
332 332
      * @param bool true if we show the footer
333
+     * @param boolean $status
333 334
      */
334 335
     public function set_footer($status)
335 336
     {
@@ -370,6 +371,7 @@  discard block
 block discarded – undo
370 371
     /**
371 372
      * Sets the header visibility
372 373
      * @param bool true if we show the header
374
+     * @param boolean $status
373 375
      */
374 376
     public function set_header($status)
375 377
     {
Please login to merge, or discard this patch.
main/inc/lib/text.lib.php 1 patch
Doc Comments   +10 added lines, -5 removed lines patch added patch discarded remove patch
@@ -52,6 +52,7 @@  discard block
 block discarded – undo
52 52
  * Converts the text of a html-document to a given encoding, the meta-tag is changed accordingly.
53 53
  * @param string $string                The input full-html document.
54 54
  * @param string                        The new encoding value to be set.
55
+ * @param string $encoding
55 56
  */
56 57
 function api_set_encoding_html(&$string, $encoding) {
57 58
     $old_encoding = api_detect_encoding_html($string);
@@ -74,7 +75,7 @@  discard block
 block discarded – undo
74 75
  * Returns the title of a html document.
75 76
  * @param string $string                The contents of the input document.
76 77
  * @param string $input_encoding        The encoding of the input document. If the value is not set, it is detected.
77
- * @param string $$output_encoding      The encoding of the retrieved title. If the value is not set, the system encoding is assumend.
78
+ * @param string $output_encoding      The encoding of the retrieved title. If the value is not set, the system encoding is assumend.
78 79
  * @return string                       The retrieved title, html-entities and extra-whitespace between the words are cleaned.
79 80
  */
80 81
 function api_get_title_html(&$string, $output_encoding = null, $input_encoding = null) {
@@ -433,7 +434,7 @@  discard block
 block discarded – undo
433 434
  * @since wordpress  2.8.1
434 435
  * @access private
435 436
  *
436
- * @param string|array $search The value being searched for, otherwise known as the needle. An array may be used to designate multiple needles.
437
+ * @param string[] $search The value being searched for, otherwise known as the needle. An array may be used to designate multiple needles.
437 438
  * @param string $subject The string being searched and replaced on, otherwise known as the haystack.
438 439
  * @return string The string with the replaced svalues.
439 440
  */
@@ -628,6 +629,7 @@  discard block
 block discarded – undo
628 629
  * @param string    The text to "cut"
629 630
  * @param int       Count of chars
630 631
  * @param bool      Whether to embed in a <span title="...">...</span>
632
+ * @param integer $maxchar
631 633
  * @return string
632 634
  * */
633 635
 function cut($text, $maxchar, $embed = false) {
@@ -645,7 +647,7 @@  discard block
 block discarded – undo
645 647
  *
646 648
  * @param mixed     Number to convert
647 649
  * @param int       Decimal points 0=never, 1=if needed, 2=always
648
- * @return mixed    An integer or a float depends on the parameter
650
+ * @return string|null    An integer or a float depends on the parameter
649 651
  */
650 652
 function float_format($number, $flag = 1) {
651 653
     if (is_numeric($number)) {
@@ -689,7 +691,7 @@  discard block
 block discarded – undo
689 691
 /**
690 692
  * Gets the week from a day
691 693
  * @param   string   Date in UTC (2010-01-01 12:12:12)
692
- * @return  int      Returns an integer with the week number of the year
694
+ * @return  string      Returns an integer with the week number of the year
693 695
  */
694 696
 function get_week_from_day($date) {
695 697
     if (!empty($date)) {
@@ -739,6 +741,9 @@  discard block
 block discarded – undo
739 741
 	return $output.$end;
740 742
 }
741 743
 
744
+/**
745
+ * @param string $glue
746
+ */
742 747
 function implode_with_key($glue, $array) {
743 748
     if (!empty($array)) {
744 749
         $string = '';
@@ -817,7 +822,7 @@  discard block
 block discarded – undo
817 822
 /**
818 823
  * @param string $string
819 824
  * @param bool $capitalizeFirstCharacter
820
- * @return mixed
825
+ * @return string
821 826
  */
822 827
 function underScoreToCamelCase($string, $capitalizeFirstCharacter = true)
823 828
 {
Please login to merge, or discard this patch.
main/inc/lib/timeline.lib.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
      * @todo the form should be auto generated
74 74
      * @param   string  url
75 75
      * @param   string  action add, edit
76
-     * @return  obj     form validator obj
76
+     * @return  FormValidator     form validator obj
77 77
      */
78 78
     public function return_form($url, $action)
79 79
     {
Please login to merge, or discard this patch.
main/inc/lib/tracking.lib.php 1 patch
Doc Comments   +13 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1287,6 +1287,8 @@  discard block
 block discarded – undo
1287 1287
      * @param   string type of time filter: 'last_week' or 'custom'
1288 1288
      * @param   string  start date date('Y-m-d H:i:s')
1289 1289
      * @param   string  end date date('Y-m-d H:i:s')
1290
+     * @param string $start_date
1291
+     * @param string $end_date
1290 1292
      * @return timestamp $nb_seconds
1291 1293
      */
1292 1294
     public static function get_time_spent_on_the_platform(
@@ -1390,7 +1392,7 @@  discard block
 block discarded – undo
1390 1392
      * Get first connection date for a student
1391 1393
      * @param    int $student_id
1392 1394
      *
1393
-     * @return    string|bool Date format long without day or false if there are no connections
1395
+     * @return    string|false Date format long without day or false if there are no connections
1394 1396
      */
1395 1397
     public static function get_first_connection_date($student_id)
1396 1398
     {
@@ -1420,7 +1422,7 @@  discard block
 block discarded – undo
1420 1422
      * @param int $student_id
1421 1423
      * @param bool $warning_message Show a warning message (optional)
1422 1424
      * @param bool $return_timestamp True for returning results in timestamp (optional)
1423
-     * @return string|int|bool Date format long without day, false if there are no connections or
1425
+     * @return string Date format long without day, false if there are no connections or
1424 1426
      * timestamp if parameter $return_timestamp is true
1425 1427
      */
1426 1428
     public static function get_last_connection_date($student_id, $warning_message = false, $return_timestamp = false)
@@ -2667,6 +2669,9 @@  discard block
 block discarded – undo
2667 2669
      * @param     array         Limit average to listed lp ids
2668 2670
      * @param     int            Session id (optional), if param $session_id is
2669 2671
      * null(default) it'll return results including sessions, 0 = session is not filtered
2672
+     * @param integer $student_id
2673
+     * @param string $course_code
2674
+     * @param integer $session_id
2670 2675
      * @return     int         Total time
2671 2676
      */
2672 2677
     public static function get_time_spent_in_lp($student_id, $course_code, $lp_ids = array(), $session_id = null)
@@ -2733,6 +2738,8 @@  discard block
 block discarded – undo
2733 2738
      * @param     int|array    Student id(s)
2734 2739
      * @param     string         Course code
2735 2740
      * @param     int         Learning path id
2741
+     * @param integer $student_id
2742
+     * @param string $course_code
2736 2743
      * @return     int         Total time
2737 2744
      */
2738 2745
     public static function get_last_connection_time_in_lp($student_id, $course_code, $lp_id, $session_id = 0)
@@ -5400,7 +5407,7 @@  discard block
 block discarded – undo
5400 5407
 
5401 5408
     /**
5402 5409
     * @param FormValidator $form
5403
-    * @return mixed
5410
+    * @return FormValidator
5404 5411
     */
5405 5412
     public static function setUserSearchForm($form)
5406 5413
     {
@@ -5439,7 +5446,6 @@  discard block
 block discarded – undo
5439 5446
      * @param   int $sessionId  The session ID (session.id)
5440 5447
      * @param   int $courseId   The course ID (course.id)
5441 5448
      * @param   int $exerciseId The quiz ID (c_quiz.id)
5442
-     * @param   int $answer     The answer status (0 = incorrect, 1 = correct, 2 = both)
5443 5449
      * @param   array   $options    An array of options you can pass to the query (limit, where and order)
5444 5450
      * @return array An array with the data of exercise(s) progress
5445 5451
      */
@@ -6876,7 +6882,7 @@  discard block
 block discarded – undo
6876 6882
      * @param int $user_id
6877 6883
      * @param int $course_id
6878 6884
      * @param int $session_id
6879
-     * @return array
6885
+     * @return string[]
6880 6886
      */
6881 6887
     public function display_login_tracking_info($view, $user_id, $course_id, $session_id = 0)
6882 6888
     {
@@ -6922,9 +6928,9 @@  discard block
 block discarded – undo
6922 6928
     /**
6923 6929
      * Displays the exercise results for a specific user in a specific course.
6924 6930
      * @param   string $view
6925
-     * @param   int $user_id    User ID
6931
+     * @param   int $userId    User ID
6926 6932
      * @param   string  $courseCode Course code
6927
-     * @return array
6933
+     * @return string[]
6928 6934
      * @todo remove globals
6929 6935
      */
6930 6936
     public function display_exercise_tracking_info($view, $userId, $courseCode)
Please login to merge, or discard this patch.