public function defaultCard()
    {
        if (! $this->hasStripeId()) {
            return;
        }

        $customer = $this->asStripeCustomer();

        foreach ($customer->sources->data as $card) {
            if ($card->id === $customer->default_source) {
                return $card;
            }
        }
    }
public function defaultCard()
    {
        if (! $this->hasStripeId()) {
            return;
        }

        $customer = $this->asStripeCustomer();

        foreach ($customer->sources->data as $card) {
            if ($card->id === $customer->default_source) {
                return $card;
            }
        }
    }
public function defaultCard ( ) { if ( ! $ this -> hasStripeId ( ) ) { return ; } $ customer = $ this -> asStripeCustomer ( ) ; foreach ( $ customer -> sources -> data as $ card ) { if ( $ card -> id === $ customer -> default_source ) { return $ card ; } } }
Get the default card for the entity.

@return \Stripe\Card|null
Get the default card for the entity .