Just discovered the following notices after adding a 2 different phone fields in a dummy content type.

Notice : Undefined index: country in phone_field_instance_settings_form() (line 115 in /docroot/sites/all/modules/contrib/phone/phone.module).
Notice : Undefined index: country in phone_field_instance_settings_form() (line 132 in /docroot/sites/all/modules/contrib/phone/phone.module).
Notice : Undefined index: country in phone_field_widget_form() (line 236 in /docroot/sites/all/modules/contrib/phone/phone.module).
CommentFileSizeAuthor
#1 phone-notice-1713148-2.patch2.1 KBmgifford
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mgifford’s picture

Status: Active » Needs review
FileSize
2.1 KB

Can confirm this. Here's a patch that should address it.

rfsbsb’s picture

How can I reproduce this?

anavarre’s picture

It's been a while but trying to reproduce now didn't show anything wrong. Can't remember exactly how I managed to get these errors in first place. @mgifford, maybe you remember?

rfsbsb’s picture

I thought it could be related to some migration problem or even some buggy installation. Another situation is an old option for empty country that doesn't exists anymore.

Anyway, I will wait for @mgifford answer. If we found out it's not happening anymore, we declare it fixed.

mgifford’s picture

Sorry.. Was too long ago.

rfsbsb’s picture

Status: Needs review » Fixed

I will consider it fixed. If someone else find a way to reproduce this, we can reopen.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

seanr’s picture

Status: Closed (fixed) » Active

This is not fixed. Just downloaded phone onto a fresh Panopoly instance and tried to add a phone field to a content type. Got the same three errors the original author got. I'm guessing there's some config setting it's expecting?

The default value for the country field in the phone field settings for should try to default to the site's country field and fall back to international if necessary, IMO.

Matt Habermehl’s picture

I can confirm that this is an issue on Panopoly installs.