Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NextSiteEntityController::environmentVariables consumer route should not be hardcoded #615

Open
mglaman opened this issue Nov 29, 2023 · 0 comments · May be fixed by #623
Open

NextSiteEntityController::environmentVariables consumer route should not be hardcoded #615

mglaman opened this issue Nov 29, 2023 · 0 comments · May be fixed by #623
Labels
area: next module enhancement New feature or request

Comments

@mglaman
Copy link
Contributor

mglaman commented Nov 29, 2023

Package

next (Drupal module)

Describe the feature request

\Drupal\next\Controller\NextSiteEntityController::environmentVariables hardcodes the paths /admin/config/services/consumer. This path should be retrieved using a URL object and the routing system, in case it ever changes.

Describe the solution you'd like

    $path = Url::fromRoute('entity.consumer.collection')->toString();
    $variables += [
      'authentication_bearer' => '# Authentication',
      'DRUPAL_CLIENT_ID' => 'Retrieve this from ' . $path,
      'DRUPAL_CLIENT_SECRET' => 'Retrieve this from ' . $path,
    ];
@mglaman mglaman added enhancement New feature or request triage A new issue that needs triage labels Nov 29, 2023
mglaman added a commit to mglaman/next-drupal that referenced this issue Dec 7, 2023
Provides dynamic consumer paths from generated URL using Consumer
collection route.

fixes chapter-three#615
@mglaman mglaman linked a pull request Dec 7, 2023 that will close this issue
7 tasks
@JohnAlbin JohnAlbin added area: next module and removed triage A new issue that needs triage labels Dec 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: next module enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants