Im getting notices for
Notice: Undefined index: link in fb_user_form_user_profile_form_alter() (line 763 of /sites/all/modules/fb/fb_user.module).
| Comment | File | Size | Author |
|---|---|---|---|
| #15 | fb-1144926-the_missing_link-15.patch | 1.52 KB | xurizaemon |
| #10 | updated-fb-token.patch | 933 bytes | tpainton |
Comments
Comment #1
scobee commentedAfter scouring the FaceBook Developers site for reference to the access tokens, I found that the 'link' token doesn't exist. It looks like it was replaced with 'id'. So...
I changed line 765 from
'!profile_page' => l($data['name'], $data['link'])));
to
'!profile_page' => l($data['name'], $data['id'])));
All seems to be working fine for me now.
Comment #2
jimsmith commentedI'm using current 7.x-3.x-dev version. Editing that line did not remove the error.
Comment #3
TikaL13 commentedHaving the same problem
Comment #4
hawkeye217 commented+1... same problem, latest -dev.
Comment #5
Prague man commentedSame problem, subs.
Comment #6
jaxpax commentedsame here
Comment #7
jaxpax commentedI followed the advice from scobee and changed 'link' to 'id', and the problem got solved.
@scobee - Thanks a bunch!
Comment #8
yareckon commentedCould someone who has done this edit provide a git format patch for it if it is still needed? Thanks.
Comment #9
jaxpax commentedHmmm, I'm not sure how to do any of that stuff. I'm not a coder so I haven't had any reasons to learn these things.
Comment #10
tpainton commentedI had same problem. The fix above worked. I am providing the following patch. This needs to be tested to make sure it doesn't cause other problems. This is for latest 7 Dev.
Comment #11
kpojeta commentedscobee - your switch worked for me - although in the latest dev release (today is 3/27/12 and I just updated) the line number is 784.
Comment #12
Dave Cohen commentedI just tried but could not reproduce the problem.
Anyway assuming that for some users link is not returned, the patch is still no good. You've avoided a php warning but now have a broken link on the page.
$data[link] is a full url. In my test, i.e. http://www.facebook.com/someuser
$data[id] is number. It shouldn't be passed into l().
A proper patch would check for the existence of $data[link] and use it only if present.
Comment #13
Abdso commentedHi, hello everybody. I am using drupal 7 and the last version of drupal for facebook. I have this problem but only when I try to edit an user account from my user account (admin account). I get this message:
Notice: Undefined index: link en fb_user_form_user_profile_form_alter() (línea 784 de /home/s12cff1b/public_html/modules/fb/fb_user.module).
The first time I installed drupal for facebook I didn't modify mi settings.php file and the result was the message appeared to users too (when an user account tried to modify its own account). I had other problems so I uninstalled all and installed again with the settings.php modified.
Now If I change "link" to "id" this message disappear but I'm not gonna do this because the message don't bother the users.
Comment #14
modctek commentedsubscribing - getting this error and I'm worried about attempting the fix suggested because of points made by #12.
Comment #15
xurizaemonI can reproduce this. Modified as per Dave's suggestion from #12, fixed a similar block in fb_test also.
Comment #16
xurizaemonWish that I always remembered to update status when attaching patches. Oh look, #1365556: Auto-switch status to "need review" when attaching a patch.
Comment #17
fluffy commentedPatch at #15 worked for me.
Comment #18
Dave Cohen commentedThanks for patches and review. Pushed.