You are here

function popup_onload_check_display_conditions in Popup On Load 8

Same name and namespace in other branches
  1. 7 popup_onload.module \popup_onload_check_display_conditions()

Determine whether the popup is allowed to display.

Parameters

object $popup_onload: Fully populated popup_onload entity object.

Return value

bool If at least one hook returns FALSE, the popup is denied.

1 call to popup_onload_check_display_conditions()
PopupOnloadController::getPopup in src/Controller/PopupOnloadController.php
Get popup.

File

./popup_onload.module, line 77
Contains main popup_onload hooks and functions.

Code

function popup_onload_check_display_conditions($popup_onload) {
  $conditions = \Drupal::moduleHandler()
    ->invokeAll('popup_onload_check_display_conditions', [
    $popup_onload,
  ]);
  return !in_array(FALSE, $conditions);
}