Using the absolute css path for simple menu icons with file_get_contents function in core may result in missed css files for simple menu icons.

Created on 29 March 2025, 9 days ago

On one of our client servers, I see a lot of errors related to this line of code in simple_menu_icons_css_alter: \Drupal::service('file_url_generator')->generateAbsoluteString($cssfile);
I see the same thing in my local environment.

.../sites/default/files/css/menu_icons_1742919384.css?stouet=Symfony\Component\HttpKernel\Exception\BadRequestHttpException: The theme must be passed as a query argument in Drupal\system\Controller\AssetControllerBase->deliver() (line 132 of /var/www/.../.../.../core/modules/system/src/Controller/AssetControllerBase.php).

I don't see the point in making an extra request to the server to be able to get menu_icons.css file. Instead, we should use the relative URLs.

πŸ› Bug report
Status

Active

Version

3.0

Component

Code

Created by

πŸ‡ΊπŸ‡¦Ukraine olegrymar

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