original_string: protected function _normalizeDomains($domains)
      {
          $result = [];
          foreach ($domains as $domain) {
              if ($domain === '*') {
                  $result[] = ['preg' => '@.@', 'original' => '*'];
                  continue;
              }
  
              $original = $preg = $domain;
              if (strpos($domain, '://') === false) {
                  $preg = ($this->_isSsl ? 'https://' : 'http://') . $domain;
              }
              $preg = '@^' . str_replace('\*', '.*', preg_quote($preg, '@')) . '$@';
              $result[] = compact('original', 'preg');
          }
  
          return $result;
      }
code: protected function _normalizeDomains($domains)
      {
          $result = [];
          foreach ($domains as $domain) {
              if ($domain === '*') {
                  $result[] = ['preg' => '@.@', 'original' => '*'];
                  continue;
              }
  
              $original = $preg = $domain;
              if (strpos($domain, '://') === false) {
                  $preg = ($this->_isSsl ? 'https://' : 'http://') . $domain;
              }
              $preg = '@^' . str_replace('\*', '.*', preg_quote($preg, '@')) . '$@';
              $result[] = compact('original', 'preg');
          }
  
          return $result;
      }
code_tokens: protected function _normalizeDomains ( $ domains ) { $ result = [ ] ; foreach ( $ domains as $ domain ) { if ( $ domain === '*' ) { $ result [ ] = [ 'preg' => '@.@' , 'original' => '*' ] ; continue ; } $ original = $ preg = $ domain ; if ( strpos ( $ domain , '://' ) === false ) { $ preg = ( $ this -> _isSsl ? 'https://' : 'http://' ) . $ domain ; } $ preg = '@^' . str_replace ( '\*' , '.*' , preg_quote ( $ preg , '@' ) ) . '$@' ; $ result [ ] = compact ( 'original' , 'preg' ) ; } return $ result ; }
docstring: Normalize the origin to regular expressions and put in an array format
  
  @param array $domains Domain names to normalize.
  @return array
docstring_tokens: Normalize the origin to regular expressions and put in an array format