Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
When drupal run tests, the token module throw erros instead of warnings when trying to replace multivaluetokens with predifined indexes on non existent data:
if (!empty($GLOBALS['drupal_test_info']['test_run_id'])) {
// Only check when tests are running.
$type_info = token_get_info($type);
if (!empty($type_info['needs-data']) && !isset($data[$type_info['needs-data']])) {
trigger_error(t('Attempting to perform token replacement for token type %type without required data', array('%type' => $type)), E_USER_WARNING);
}
}
Because of this little thing, i need to patch how multivalue token replacement happens for the entity module
Comment | File | Size | Author |
---|---|---|---|
#2 | entity-multivalue-token-replacement-fix-2341611-0.patch | 1.79 KB | topicus |
#1 | entity-multivalue-token-replacement-fix-2341611-0.patch | 1.02 KB | drkloc |
Comments
Comment #1
drkloc CreditAttribution: drkloc commentedComment #2
topicus CreditAttribution: topicus commentedComment #3
acouch CreditAttribution: acouch commentedComment #4
fagoPlease do not rtbc your own patches. Also, this could need some more context what it is about.
> with predifined indexes on non existent data
No idea what that means.