original_string: protected function setSortingOrder()
      {
          if (null !== $this->info->list->default_sort) {
              return $this;
          }
  
          if ($this->info->list->orderable && $this->info->list->getOrderableColumn()) {
              $this->info->list->default_sort = $this->info->list->getOrderableColumn();
          } elseif ($this->info->timestamps) {
              $this->info->list->default_sort = $this->info->timestamp_created;
          } elseif ($this->info->incrementing) {
              $this->info->list->default_sort = $this->model->getKeyName();
          }
  
          return $this;
      }
code: protected function setSortingOrder()
      {
          if (null !== $this->info->list->default_sort) {
              return $this;
          }
  
          if ($this->info->list->orderable && $this->info->list->getOrderableColumn()) {
              $this->info->list->default_sort = $this->info->list->getOrderableColumn();
          } elseif ($this->info->timestamps) {
              $this->info->list->default_sort = $this->info->timestamp_created;
          } elseif ($this->info->incrementing) {
              $this->info->list->default_sort = $this->model->getKeyName();
          }
  
          return $this;
      }
code_tokens: protected function setSortingOrder ( ) { if ( null !== $ this -> info -> list -> default_sort ) { return $ this ; } if ( $ this -> info -> list -> orderable && $ this -> info -> list -> getOrderableColumn ( ) ) { $ this -> info -> list -> default_sort = $ this -> info -> list -> getOrderableColumn ( ) ; } elseif ( $ this -> info -> timestamps ) { $ this -> info -> list -> default_sort = $ this -> info -> timestamp_created ; } elseif ( $ this -> info -> incrementing ) { $ this -> info -> list -> default_sort = $ this -> model -> getKeyName ( ) ; } return $ this ; }
docstring: Sets default sorting order, if empty.
  
  @return $this
docstring_tokens: Sets default sorting order if empty .