Services/SiteManagementModel.php
public function getDefaultLanguageOfSite($site, $bypass = false){
        $timeStamp = time();
        $response = $this->getSite($site);
        if($response->error->exist){
            return $response;
        }
        $language = $response->result->set->getDefaultLanguage();
        if(is_null($language)){
            return new ModelResponse(null, 1, 0, null, error, 'E:S:005', 'Default language is not set.', $timeStamp, time());
        }

        $lModel= $this->kernel->getContainer()->get('multilanguagesupport.model');
        $lResponse = $lModel->getLanguage($language);
        if ($lResponse->error->exist) {
            return $lResponse;
        }
        $language = $lResponse->result->set;
        if($bypass){
            return $language;
        }
        return new ModelResponse($language, 1, 0, null, false, 'S:D:002', 'Entries successfully fetched from database.', $timeStamp, time());
    }
public function getDefaultLanguageOfSite($site, $bypass = false){
        $timeStamp = time();
        $response = $this->getSite($site);
        if($response->error->exist){
            return $response;
        }
        $language = $response->result->set->getDefaultLanguage();
        if(is_null($language)){
            return new ModelResponse(null, 1, 0, null, error, 'E:S:005', 'Default language is not set.', $timeStamp, time());
        }

        $lModel= $this->kernel->getContainer()->get('multilanguagesupport.model');
        $lResponse = $lModel->getLanguage($language);
        if ($lResponse->error->exist) {
            return $lResponse;
        }
        $language = $lResponse->result->set;
        if($bypass){
            return $language;
        }
        return new ModelResponse($language, 1, 0, null, false, 'S:D:002', 'Entries successfully fetched from database.', $timeStamp, time());
    }
@name 			getDefaultLanguageOfSite()

@since			1.0.6
@version         1.1.3

@author          Can Berkol
@author          Said İmamoğlu

@use             $this->getSite()

@param           mixed           $site
@param           bool            $bypass

@return          \BiberLtd\Bundle\CoreBundle\Responses\ModelResponse