security upadtes

This commit is contained in:
Bachir Soussi Chiadmi
2017-09-25 15:16:35 +02:00
parent 650c6448e4
commit 8d8a60b615
240 changed files with 3022 additions and 1300 deletions

View File

@@ -0,0 +1,12 @@
name = References UUID
core = 7.x
package = Fields
dependencies[] = references
dependencies[] = uuid
; Information added by Drupal.org packaging script on 2017-04-18
version = "7.x-2.2"
core = "7.x"
project = "references"
datestamp = "1492534745"

View File

@@ -0,0 +1,33 @@
<?php
/**
* @file
* This provides UUID support for node and user references
*/
/**
* Implements hook_field_uuid_load().
*/
function node_reference_field_uuid_load($entity_type, $entity, $field, $instance, $langcode, &$items) {
entity_property_id_to_uuid($items, 'node', 'nid');
}
/**
* Implements hook_field_uuid_presave().
*/
function node_reference_field_uuid_presave($entity_type, $entity, $field, $instance, $langcode, &$items) {
entity_property_uuid_to_id($items, 'node', 'nid');
}
/**
* Implements hook_field_uuid_load().
*/
function user_reference_field_uuid_load($entity_type, $entity, $field, $instance, $langcode, &$items) {
entity_property_id_to_uuid($items, 'user', 'uid');
}
/**
* Implements hook_field_uuid_presave().
*/
function user_reference_field_uuid_presave($entity_type, $entity, $field, $instance, $langcode, &$items) {
entity_property_uuid_to_id($items, 'user', 'uid');
}