Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
jquery.min.js:4 Uncaught TypeError: Cannot read property 'length' of undefined
at Function.each (jquery.min.js:4)
at Object.attach (linkit.field.js?v=7.3:21)
at Object.<anonymous> (drupal.js?osmfox:76)
at Function.each (jquery.min.js:4)
at Object.Drupal.attachBehaviors (drupal.js?osmfox:74)
at Object.insert (ajax.js?v=7.54:570)
at Drupal.ajax.success (ajax.js?v=7.54:428)
at Object.success (ajax.js?v=7.54:189)
at Object.c.success (jquery.form.min.js?v=2.69:11)
at c (jquery.min.js:4)
each @ jquery.min.js:4
attach @ linkit.field.js?v=7.3:21
(anonymous) @ drupal.js?osmfox:76
each @ jquery.min.js:4
Drupal.attachBehaviors @ drupal.js?osmfox:74
insert @ ajax.js?v=7.54:570
Drupal.ajax.success @ ajax.js?v=7.54:428
success @ ajax.js?v=7.54:189
c.success @ jquery.form.min.js?v=2.69:11
c @ jquery.min.js:4
fireWith @ jquery.min.js:4
k @ jquery.min.js:6
r @ jquery.min.js:6
I fixed this via changing linkit.field.js:
17 if (undefined === settings.linkit || null === settings.linkit.fields) {
changed to:
17 if (undefined === settings.linkit || null === settings.linkit.fields || undefined === settings.linkit.fields) {
Comments
Comment #2
ccjjmartin CreditAttribution: ccjjmartin as a volunteer commentedComment #3
eelkeblokPlease have a look at the description of the issue statuses at https://www.drupal.org/issue-queue/status. "Patch (To be ported)" is not a status to assign before a patch has been reviewed by the community, even if there were actually a *patch* ;) (and would typically be set by whoever commits the patch in a particular version of the module). Also, I don't think this qualifies as Critical ("This status is used to designate broken functionality that makes the project unusable.", see https://www.drupal.org/node/314328). Given that the other issue is older and actually has a patch I think it's best to close this and continue in the other issue. Please review the patch in there to see if it solves your problem (which would constitute as a review, so please leave your feedback, in that case).