original_string: public static function get_sorted_subjects() {
          $subjects = get_string_manager()->load_component_strings('edufields', current_language());
  
          // Sort the subjects.
          $return  = [];
          asort($subjects);
          foreach ($subjects as $key => $option) {
              $keylength = strlen($key);
              if ($keylength == 12) {
                  $return[$key] = $option; // We want only selectable categories.
              }
          }
          return $return;
      }
code: public static function get_sorted_subjects() {
          $subjects = get_string_manager()->load_component_strings('edufields', current_language());
  
          // Sort the subjects.
          $return  = [];
          asort($subjects);
          foreach ($subjects as $key => $option) {
              $keylength = strlen($key);
              if ($keylength == 12) {
                  $return[$key] = $option; // We want only selectable categories.
              }
          }
          return $return;
      }
code_tokens: public static function get_sorted_subjects ( ) { $ subjects = get_string_manager ( ) -> load_component_strings ( 'edufields' , current_language ( ) ) ; // Sort the subjects. $ return = [ ] ; asort ( $ subjects ) ; foreach ( $ subjects as $ key => $ option ) { $ keylength = strlen ( $ key ) ; if ( $ keylength == 12 ) { $ return [ $ key ] = $ option ; // We want only selectable categories. } } return $ return ; }
docstring: Retrieve all the sorted course subjects
  
  @return array $subjects
docstring_tokens: Retrieve all the sorted course subjects