I'm doing a drupal 7 website, I've now started to experience a "EntityMalformedException: Missing bundle property on entity of type node. in entity_extract_ids() (line 7820 of C:\xampp----\includes\common.inc)." error whn I try to view a node in full view mode and only if I'm logged in as administrator.
This is happening here:
if (!empty($info['entity keys']['bundle'])) {
// Explicitly fail for malformed entities missing the bundle property.
if (!isset($entity->{$info['entity keys']['bundle']}) || $entity->{$info['entity keys']['bundle']} === '') {
var_dump($entity);
throw new EntityMalformedException(t('Missing bundle property on entity of type @entity_type.', array('@entity_type' => $entity_type)));
}
I found some pages about this error but none seems to apply to my case. I put a var_dump just before the instruction throwing the exception and all I get is bool(false). I've checked all the bool fields of the node and they all have #bundle correctly set.
I think the problem might have started after installing the database optimization module. I found some information regardin this error and clearing the form_cache but I didn't understand if this can apply to my case.
I guess these hints are enough to trace the problem for a drupal expert, unfortunately not for me.
Any suggestion? Thanks
var_dump
ordpm()
output the node object? It should contain the$node->type
property. – AKS May 9 '15 at 22:05