original_string: public function defaultLocale()
      {
          $locale = $this->getCore()->config('locale.translation-default');
  
          if ($locale) {
              return $locale;
          }
  
          // Fall back to default based on CMS configuration and app locale.
          $locale    = app()->getLocale();
          $available = $this->availableLocales();
  
          // If no translation locales are set, use app's locale as default.
          // If current app locale is available, use it as default.
          if ( ! count($available) || in_array($locale, $available)) {
              return $locale;
          }
  
          return head($available);
      }
code: public function defaultLocale()
      {
          $locale = $this->getCore()->config('locale.translation-default');
  
          if ($locale) {
              return $locale;
          }
  
          // Fall back to default based on CMS configuration and app locale.
          $locale    = app()->getLocale();
          $available = $this->availableLocales();
  
          // If no translation locales are set, use app's locale as default.
          // If current app locale is available, use it as default.
          if ( ! count($available) || in_array($locale, $available)) {
              return $locale;
          }
  
          return head($available);
      }
code_tokens: public function defaultLocale ( ) { $ locale = $ this -> getCore ( ) -> config ( 'locale.translation-default' ) ; if ( $ locale ) { return $ locale ; } // Fall back to default based on CMS configuration and app locale. $ locale = app ( ) -> getLocale ( ) ; $ available = $ this -> availableLocales ( ) ; // If no translation locales are set, use app's locale as default. // If current app locale is available, use it as default. if ( ! count ( $ available ) || in_array ( $ locale , $ available ) ) { return $ locale ; } return head ( $ available ) ; }
docstring: Returns default translation locale.
  
  @return string
docstring_tokens: Returns default translation locale .