Skip to content

Support FCQN for GatewayFactory #650

@Mouke

Description

@Mouke

Hello there !

I'm testing Omnipay for the first time and I'd like to suggest an enhancement. After a small search in issues, i've seen no traces of such suggestion.

Currently, to use Omnipay/Stripe's PaymentIntents Gateway, I have to write this code :
$gateway = Omnipay\Omnipay::create('Stripe\PaymentIntents');

Why not allow to use the gateway FQCN in \Omnipay\Common\Helper::getGatewayClassName ? It would be much easier (and cleaner) to write this :
use Omnipay\Stripe\PaymentIntentsGateway; $gateway = Omnipay\Omnipay::create(PaymentIntentsGateway::class);

If you want, I would gladly make that small update and suggest a PR for that.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions