Fixed "new static" is unsafe

This commit is contained in:
Kyle Huynh 2023-06-06 11:37:11 -04:00
parent 0c2504c4c7
commit 9557ca17d5
7 changed files with 9 additions and 6 deletions

View file

@ -40,7 +40,8 @@ function advanced_search_theme() {
function advanced_search_library_info_alter(&$libraries, $extension) {
if ($extension == 'facets') {
// Override facets module javascript with customizations.
$path = '/' . drupal_get_path('module', 'advanced_search') . '/js/facets';
// https://www.drupal.org/node/2940438
$path = '/' . \Drupal::service('extension.list.module')->getPath('advanced_search') . '/js/facets';
$libraries['soft-limit']['js'] = [
"$path/soft-limit.js" => [],
];