You are here

function _signup_load_scheduler_includes in Signup 5.2

Same name and namespace in other branches
  1. 6.2 includes/scheduler.inc \_signup_load_scheduler_includes()
  2. 6 includes/scheduler.inc \_signup_load_scheduler_includes()
  3. 7 includes/scheduler.inc \_signup_load_scheduler_includes()

Load relevant scheduler backend include file(s).

Decides which include files are needed based on which modules exist and which versions are loaded.

1 call to _signup_load_scheduler_includes()
_signup_initialize_scheduler_backend in ./signup.module
Initialize the necessary scheduler backend(s).

File

includes/scheduler.inc, line 15
Code necessary to determine which scheduler backend(s) to use.

Code

function _signup_load_scheduler_includes() {
  if (defined('EVENT_API') && EVENT_API == '5.2') {
    require_once SIGNUP_PATH . '/includes/event.5x-2.inc';
  }
  elseif (module_exists('event')) {
    require_once SIGNUP_PATH . '/includes/event.5x-1.inc';
  }
  if (variable_get('date_api_version', 0) == '5.2') {
    require_once SIGNUP_PATH . '/includes/date.inc';
    require_once SIGNUP_PATH . '/includes/date.5x-2.inc';
  }
  elseif (module_exists('date')) {
    require_once SIGNUP_PATH . '/includes/date.inc';
    require_once SIGNUP_PATH . '/includes/date.5x-1.inc';
  }
}