Posted by fraweg on January 21, 2012 at 5:13am
7 followers
| Project: | User Relationships |
| Version: | 7.x-1.x-dev |
| Component: | Miscellaneous |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (duplicate) |
Issue Summary
Hello,
I have this error (when I go to a profile with no relationship) in combination with Authors Pane:
Notice: Undefined variable: relationship in user_relationships_preprocess_author_pane() (line 70 of /...../sites/all/modules/user_relationships/user_relationships.author-pane.inc).
Notice: Trying to get property of non-object in user_relationships_preprocess_author_pane() (line 70 of /...../sites/all/modules/user_relationships/user_relationships.author-pane.inc).I still have this problem until I have a relationship to the depend user.
I use:
Drupal 7.10
UR 7.x-1.x-dev
The newest Author Pane 7.x-2.0-alpha2
Thanks for any Help!
Comments
#1
Change $relationship to $rtype in line 70
$css_class = array(str_replace(' ', '-', $relationship->name)change to
$css_class = array(str_replace(' ', '-', $rtype->name)Check this similar problem -> http://drupal.org/node/1217908
#2
change title...
#3
Hello,
THANKS for your fast answer.. this seems to work for me.
best regards
Frank
#4
This issue (or something very similar) is present in 6.x as well.
Notice: Undefined offset: 0 in user_relationships_api_preprocess_author_pane() (line 36 of /drupal6/sites/all/modules/user_relationships/user_relationships_api/user_relationships_api.author-pane.inc).Notice: Trying to get property of non-object in user_relationships_api_preprocess_author_pane() (line 40 of /drupal6/sites/all/modules/user_relationships/user_relationships_api/user_relationships_api.author-pane.inc).
#5
Patch for this issue can be found in #1217908: Undefined variable: relationship in user_relationships_preprocess_author_pane().
Sorry for making duplicated issues, but I moved the other issue from Author Pane.
#6
Drupal 6 issue was actually not related and is now fixed.
Closing this as a duplicate since we have a patch at #1217908: Undefined variable: relationship in user_relationships_preprocess_author_pane().
#7
Hi,
Please apply the attached patch file to get desired results.
Regards,
Hardik
#8
Hi,
In add to the previous comment I had posted,
Also, you have to apply the code of user_relationships.author-pane.inc needs to be replaced with the code in attachment.
#9
If you have read the latest comment before you posted this issue is a duplicate of this http://drupal.org/node/1217908 and if you check that issue, you can see that is has been fixed.
#10
Hi Christoffer,
As per my knowledge, both are similar issues but not the same.Both have the different reasons to occur different problems. So,both have different solutions,too.
And only because of it, this issue has been posted as different post, not on the same post... :) :) :)
Anyway, thanks for you time and suggestions!!
Regards,
Hardik