original_string: public function getSort($sortName): ?OrderBy
      {
          [$name, $sorts] = $this->getArrayAndKeyName($sortName, 'sorts');
  
          return array_first($sorts, function ($sort) use ($name) {
              return $sort->getName() === $name;
          });
      }
code: public function getSort($sortName): ?OrderBy
      {
          [$name, $sorts] = $this->getArrayAndKeyName($sortName, 'sorts');
  
          return array_first($sorts, function ($sort) use ($name) {
              return $sort->getName() === $name;
          });
      }
code_tokens: public function getSort ( $ sortName ) : ? OrderBy { [ $ name , $ sorts ] = $ this -> getArrayAndKeyName ( $ sortName , 'sorts' ) ; return array_first ( $ sorts , function ( $ sort ) use ( $ name ) { return $ sort -> getName ( ) === $ name ; } ) ; }
docstring: It returns single sort by field name
  
  @param string $sortName Sort field name
  
  @throws InvalidArgumentException
  
  @return OrderBy
docstring_tokens: It returns single sort by field name