You are here

function clamav_entity_create in ClamAV 2.x

Same name and namespace in other branches
  1. 8 clamav.module \clamav_entity_create()

Implements hook_entity_create().

Attach a scanner to all entities that implement Drupal\file\FileInterface.

File

./clamav.module, line 15
Controls behaviour of anti-virus integration with ClamAV.

Code

function clamav_entity_create($entity) {
  if (is_a($entity, 'Drupal\\file\\FileInterface')) {
    $entity->clamav_attemptScan = TRUE;
  }
}