Commit b4309e88 authored by Alec Smrekar's avatar Alec Smrekar Committed by usingsession
Browse files

Issue #3270952 by alecsmrekar: Module tries to load a non-existent css file

parent bd876c38
Loading
Loading
Loading
Loading
+3 −2
Changes for popup_message.module: 3 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -40,11 +40,12 @@ function popup_message_help($route_name, RouteMatchInterface $route_match) {
 * Implements hook_library_info_alter().
 */
function popup_message_library_info_alter(array &$libraries, $extension) {
  if ($extension === 'popup_message') {
    $config_popup = \Drupal::configFactory()->getEditable('popup_message.settings');
    $style = $config_popup->get('style');

  if ($extension === 'popup_message') {
    if ($style) {
      $libraries['popup_message_style']['css']['base'] = [];
      $libraries['popup_message_style']['css']['base']['styles' . '/' . $style] = [];
    }
  }
}