Skip to content

Issue with guzzle configuration #228

Description

@kidager

Issue / Motivation:

When additionalConfigKeys is defined in a provider, the guzzle configuration is dropped.

Expected behavior:

When calling ConfigRetriever::fromServices, ConfigRetriever->additionalConfigKeys should contain the guzzle key if it was defined in the service.

Actual behavior:

When additionalConfigKeys is defined in a provider, the guzzle configuration is dropped.

Steps to reproduce the behavior:

In this example, the guzzle is defined in the service configuration, however, since the provider defines the additionalConfigKeys method, guzzle configuration gets ignored.

  • SampleProvider.php

    // ...
    class SampleProvider extends AbstractProvider
    {
        // ...
        public static function additionalConfigKeys()
        {
            return ['config1', 'config2'];
        }
        // ...
    }
  • Listener

    $socialiteWasCalled->extendSocialite('sample-provider', SampleProvider::class);
  • config/services.php

    'sample-provider' => [
        'client_id' => 'sample-provider-client-id',
        'client_secret' => 'sample-provider-client-secret',
        'redirect' => 'sample-provider-redirect-url',
        'config1' => 'foo',
        'realms' => 'bar',
        'guzzle' => [
            'verify' => false,
        ],
    ],

Proposed solution:

See #227

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions