Ran into a pwob when I installed commerce subscription and tested a subscription from an anonymous user using confirmation email link. After they completed their profile details (password and/or avatar image) it issued this error when the test user tried to save :

Uninitialized string offset: 0 in entity_metadata_field_property_get() (line 406 of /var/../profiles/commerce_kickstart/modules/entity/modules/callbacks.inc).

On the back end - it didn't apply subscription validity date when the order came in from an anonymous user and while the order showed up in the store - completing the order didn't add subscription end date either.

So - the only way to get a subscription was to ask the user register - then ask them to come back and order a subscription. Which sux really ..

It was fixed using a hint from here: http://drupal.org/node/1429646 - basically - 'Edit the "Apply bought subscription time" rule to apply more weight (larger number), so that it triggers after new account has been created'

.. It all seems to work now, but I didn't specifically use features overide module to fix - so assuming it will break again when I update ..

NOW - onto assigning roles - is there a specific 'commerce content access' module out there anyone can can recommend with commerce subscription?

Cheers - Jon

.. I was able

Comments

jdexter’s picture

Title: Anonymous Subscriber :: Uninitialized string offset: 0 in entity_metadata_field_property_get() » UPDATE: Anonymous Subscriber :: Uninitialized string offset: 0 in entity_metadata_field_property_get()
Priority: Normal » Minor

OK - updated to current versions of entity_field_form and commerce_features and its presenting error again when a user bypasses subscription system and simply creates a account and then tries to update password/icon/user name .. basically - any update to user account.

The changes and updates actually take, but the notice keeps tripping until the user actually subscribes ..

Willing to pass in any debug data or run any configs I can .. May simply ignore the notices to get the site live, but thought I'd better kick this new twist in ..

Cheers - Jon

jordiserra’s picture

The error is still here... any plans to solve it?

bessone’s picture

Just found this error on edit a user

Referrer	http://example.com/user/169/edit

Message	Notice: Uninitialized string offset: 0 in entity_metadata_field_property_get() (linea 407 di /var/www/web/sites/all/modules/entity/modules/callbacks.inc).

Any clue?

cornelyus’s picture

I'm also registering this..

Notice: Uninitialized string offset: 0 in entity_metadata_field_property_get() (line 407 of XXX/callbacks.inc).

And this is interfering with my user profile picture.. it deletes the picture once I save it..

flatfeat’s picture

For me, I was getting this error because the new user had not actually been assigned a subscription validity date during the checkout process. I was getting this error when I tried to log in as my new user using the link in the "welcome email." After trying to create and save a password, I got the above error. After I manually gave the new user an expiration date, I was able to successfully create a password as the new user, and the error went away. Not sure why that date was not filled out during checkout.

EDIT: OK, following #1 here did the trick for me (http://drupal.org/node/1554050). Setting the weight to 3 for "Apply bought subscription time" worked.

likewhoa’s picture

Status: Active » Closed (duplicate)