original_string: public function findByModNames(array $modNames): array
      {
          $result = [];
          if (count($modNames) > 0) {
              $queryBuilder = $this->entityManager->createQueryBuilder();
              $queryBuilder->select(['mc', 'm'])
                           ->from(ModCombination::class, 'mc')
                           ->innerJoin('mc.mod', 'm')
                           ->andWhere('m.name IN (:modNames)')
                           ->addOrderBy('mc.order', 'ASC')
                           ->setParameter('modNames', array_values($modNames));
  
              $result = $queryBuilder->getQuery()->getResult();
          }
          return $result;
      }
code: public function findByModNames(array $modNames): array
      {
          $result = [];
          if (count($modNames) > 0) {
              $queryBuilder = $this->entityManager->createQueryBuilder();
              $queryBuilder->select(['mc', 'm'])
                           ->from(ModCombination::class, 'mc')
                           ->innerJoin('mc.mod', 'm')
                           ->andWhere('m.name IN (:modNames)')
                           ->addOrderBy('mc.order', 'ASC')
                           ->setParameter('modNames', array_values($modNames));
  
              $result = $queryBuilder->getQuery()->getResult();
          }
          return $result;
      }
code_tokens: public function findByModNames ( array $ modNames ) : array { $ result = [ ] ; if ( count ( $ modNames ) > 0 ) { $ queryBuilder = $ this -> entityManager -> createQueryBuilder ( ) ; $ queryBuilder -> select ( [ 'mc' , 'm' ] ) -> from ( ModCombination :: class , 'mc' ) -> innerJoin ( 'mc.mod' , 'm' ) -> andWhere ( 'm.name IN (:modNames)' ) -> addOrderBy ( 'mc.order' , 'ASC' ) -> setParameter ( 'modNames' , array_values ( $ modNames ) ) ; $ result = $ queryBuilder -> getQuery ( ) -> getResult ( ) ; } return $ result ; }
docstring: Finds the combinations where the specified mod names are the main mod of.
  @param array|string[] $modNames
  @return array|ModCombination[]
docstring_tokens: Finds the combinations where the specified mod names are the main mod of .