You are here

function media_entity_document_requirements in Media entity document 8

Implements hook_requirements().

File

./media_entity_document.install, line 20
Install, uninstall and update hooks for Media entity document module.

Code

function media_entity_document_requirements() {
  $requirements = [];
  if (version_compare(\Drupal::VERSION, '8.4.0', '>=') && \Drupal::moduleHandler()
    ->moduleExists('media')) {
    $requirements['media_entity_document: Not compatible with core Media'] = [
      'title' => t('Core Media'),
      'description' => t("Media Entity Document's functionality has been merged into the core Media module, so it cannot be installed alongside core Media."),
      'severity' => REQUIREMENT_ERROR,
    ];
  }
  return $requirements;
}