You are here

gelf.install in GELF 8

Same filename and directory in other branches
  1. 6 gelf.install
  2. 7 gelf.install

Install functions for the gelf module.

File

gelf.install
View source
<?php

/**
 * @file Install functions for the gelf module.
 */

/**
 * Implements hook_requirements().
 *
 * Indicate whether the gelf library requirement is met.
 */
function gelf_requirements($phase) {
  $requirements = array();
  if ($phase == 'runtime') {
    if (!gelf_require()) {
      $requirements['gelf'] = array(
        'value' => t('Not installed'),
        'severity' => REQUIREMENT_ERROR,
        'description' => t('GELF module requires the GELF PHP library to be installed.  View the README in the GELF module directory for installation instructions.'),
      );
    }
    else {
      $requirements['gelf'] = array(
        'value' => t('Installed'),
        'severity' => REQUIREMENT_OK,
      );
    }
    $requirements['gelf']['title'] = t('GELF-PHP Library');
  }
  return $requirements;
}

Functions

Namesort descending Description
gelf_requirements Implements hook_requirements().