lib/Braintree/PayPalAccountGateway.php
private function _validateId($identifier = null, $identifierType = 'token')
    {
        if (empty($identifier)) {
           throw new InvalidArgumentException(
                   'expected paypal account id to be set'
                   );
        }
        if (!preg_match('/^[0-9A-Za-z_-]+$/', $identifier)) {
            throw new InvalidArgumentException(
                    $identifier . ' is an invalid paypal account ' . $identifierType . '.'
                    );
        }
    }
private function _validateId($identifier = null, $identifierType = 'token')
    {
        if (empty($identifier)) {
           throw new InvalidArgumentException(
                   'expected paypal account id to be set'
                   );
        }
        if (!preg_match('/^[0-9A-Za-z_-]+$/', $identifier)) {
            throw new InvalidArgumentException(
                    $identifier . ' is an invalid paypal account ' . $identifierType . '.'
                    );
        }
    }
private function _validateId ( $ identifier = null , $ identifierType = 'token' ) { if ( empty ( $ identifier ) ) { throw new InvalidArgumentException ( 'expected paypal account id to be set' ) ; } if ( ! preg_match ( '/^[0-9A-Za-z_-]+$/' , $ identifier ) ) { throw new InvalidArgumentException ( $ identifier . ' is an invalid paypal account ' . $ identifierType . '.' ) ; } }
verifies that a valid paypal account identifier is being used
@ignore
@param string $identifier
@param Optional $string $identifierType type of identifier supplied, default 'token'
@throws InvalidArgumentException
verifies that a valid paypal account identifier is being used