public function get($name = null)
  {
    if(count($this->connectors) > 0)
    {    
      if(!is_null($name))
      {
        if(!isset($this->connectors[$name]))
          throw new \Exception("unknown Connector: $name");
        
        return $this->connectors[$name];
      }
      
      return current($this->connectors);
    }
    throw new \Exception('No Connectors found');
  }
public function get($name = null)
  {
    if(count($this->connectors) > 0)
    {    
      if(!is_null($name))
      {
        if(!isset($this->connectors[$name]))
          throw new \Exception("unknown Connector: $name");
        
        return $this->connectors[$name];
      }
      
      return current($this->connectors);
    }
    throw new \Exception('No Connectors found');
  }
public function get ( $ name = null ) { if ( count ( $ this -> connectors ) > 0 ) { if ( ! is_null ( $ name ) ) { if ( ! isset ( $ this -> connectors [ $ name ] ) ) throw new \ Exception ( "unknown Connector: $name" ) ; return $ this -> connectors [ $ name ] ; } return current ( $ this -> connectors ) ; } throw new \ Exception ( 'No Connectors found' ) ; }
get an Connector by its name or it will return the default Connector
@param string $name Index of the chosen Connector
@return FP\WHMCS\Connector
get an Connector by its name or it will return the default Connector