I have this error on every page where an Ubercart product image is displayed and Google search does bring up this error quite a few times as well.

It is possible in the uc_store admin screen to set the uc_product_image_widget variable to be none, but he uc_product_get_image_widget() function does not allow for this as it will call uc_store_get_image_widgets() and look for an array key called none, which doesn't exist, so a notice is thrown.

8.x is not affected because of #1331760: Improve product image widget.

Comments

stefan.r’s picture

Status: Active » Needs review
StatusFileSize
new1.11 KB

Just to clarify, this notice will appear if you choose not to use Colorbox/Thickbox/Lightbox for product images despite any of them being installed. See related issues for any background on this.

Status: Needs review » Needs work

The last submitted patch, 1: ubercart-2328513-notice.patch, failed testing.

stefan.r’s picture

Project: Colorbox » Ubercart
Version: 7.x-2.x-dev » 7.x-3.x-dev

Oops!

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 1: ubercart-2328513-notice.patch, failed testing.

stefan.r’s picture

Status: Needs work » Needs review
StatusFileSize
new1.11 KB

Status: Needs review » Needs work

The last submitted patch, 6: ubercart-2328513-notice-6.patch, failed testing.

stefan.r’s picture

Status: Needs work » Needs review
StatusFileSize
new1.71 KB

Those testbot exceptions are unrelated to this patch, but submitting a fix for them just so this is green :)

TR queued 8: ubercart-2328513-notice-8.patch for re-testing.

stefan.r’s picture

StatusFileSize
new1.71 KB
stefan.r’s picture

StatusFileSize
new1.11 KB

reroll

  • TR committed 8038e61 on 7.x-3.x authored by stefan.r
    Issue #2328513 by stefan.r: Notice: Undefined index: none in...

  • TR committed 5872512 on 6.x-2.x authored by stefan.r
    Issue #2328513 by stefan.r: Notice: Undefined index: none in...
tr’s picture

Status: Needs review » Fixed

Committed fix to 7.x-3.x, cherry-picked it into 6.x-2.x.
No fix needed for 8.x-4.x.

Thanks!

Status: Fixed » Closed (fixed)

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