Unable to call controller function due to wrong service name

Created on 13 November 2024, 9 days ago

Problem

The latest version has issue when the frontend is calling "/language-suggestion/get-county-code"

The errorshows

The website encountered an unexpected error. Try again later.

InvalidArgumentException: The controller for URI "/en/language-suggestion/get-county-code" is not callable. in Drupal\Core\Controller\ControllerResolver->getControllerFromDefinition() (line 53 of core/lib/Drupal/Core/Controller/ControllerResolver.php).

Steps to reproduce

  1. Install the latest 8.x-1.x
  2. Enable module
  3. Try open '/en/language-suggestion/get-county-code'

Proposed resolution

The service registered in language_suggestion.services.yml doesn't matches the service name retrieved in LanguageSuggestionController.php line 37

Fix the language_suggestion.services.yml file to resolve the issue

🐛 Bug report
Status

Active

Version

1.0

Component

Code

Created by

🇹🇼Taiwan amourow

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024