original_string: public static function sort_custom_menu_items(custom_menu_item $itema, custom_menu_item $itemb) {
          $itema = $itema->get_sort_order();
          $itemb = $itemb->get_sort_order();
          if ($itema == $itemb) {
              return 0;
          }
          return ($itema > $itemb) ? +1 : -1;
      }
code: public static function sort_custom_menu_items(custom_menu_item $itema, custom_menu_item $itemb) {
          $itema = $itema->get_sort_order();
          $itemb = $itemb->get_sort_order();
          if ($itema == $itemb) {
              return 0;
          }
          return ($itema > $itemb) ? +1 : -1;
      }
code_tokens: public static function sort_custom_menu_items ( custom_menu_item $ itema , custom_menu_item $ itemb ) { $ itema = $ itema -> get_sort_order ( ) ; $ itemb = $ itemb -> get_sort_order ( ) ; if ( $ itema == $ itemb ) { return 0 ; } return ( $ itema > $ itemb ) ? + 1 : - 1 ; }
docstring: Sorts two custom menu items
  
  This function is designed to be used with the usort method
  usort($this->children, array('custom_menu','sort_custom_menu_items'));
  
  @static
  @param custom_menu_item $itema
  @param custom_menu_item $itemb
  @return int
docstring_tokens: Sorts two custom menu items