entity getPropertyInfo() not working I am working with the entity_metadata_wrapper, and I found online this function to display all of the wrapper's properties.

$billing_profile = commerce_customer_profile_load($order-&gt;commerce_customer_billing['und'][0]['profile_id']);
$billingWrapper = entity_metadata_wrapper('commerce_customer', $billing_profile);
dpm($billingWrapper-&gt;getPropertyInfo());


However, it gives me an error.


  PHP Fatal error:  Call to undefined method EntityValueWrapper::getPropertyInfo()


When I googled the function, it came up as EntityStructureWrapper::getPropertyInfo(),  where I see that its not a function of EntityValueWrapper, but rather EntityStructureWrapper.

How do I create that class instead of using the code I found?
Commerce customer only defines a commerce_customer_profile entity type (not commerce_customer), so changing the second line to this should fix it:

$billingWrapper = entity_metadata_wrapper('commerce_customer_profile', $billing_profile);