sarvan75 / yii-user-management

Automatically exported from code.google.com/p/yii-user-management
0 stars 0 forks source link

Call to a member function getFriends() on a non-object #192

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. YIIC webapp
2. Follow 
http://code.google.com/p/yii-user-management/wiki/InstallationInstructions
3. attempt to view profile

What is the expected output? What do you see instead?
Expected output is a view of the profile, instead fatal error of Call to a 
member function getFriends() on a non-object

What version of the product are you using? On what operating system?
Most recent SVN checkout, linux

Please provide any additional information below.

Original issue reported on code.google.com by rhal...@gmail.com on 7 May 2012 at 4:33

GoogleCodeExporter commented 9 years ago
Fatal error: Call to a member function getFriends() on a non-object in 
/home/rhall86/aircheck.dreamhosters.com/protected/modules/friendship/controllers
/YumFriendshipController.php on line 150

Original comment by rhal...@gmail.com on 7 May 2012 at 4:43

GoogleCodeExporter commented 9 years ago
removing friendships array results in:

CDbCommand failed to execute the SQL statement: SQLSTATE[42S22]: Column not 
found: 1054 Unknown column 'demo' in 'where clause'. The SQL statement executed 
was: SELECT * FROM `message` `t` WHERE to_user_id = demo and message_read = 0 
ORDER BY timestamp DESC LIMIT 10

Original comment by rhal...@gmail.com on 7 May 2012 at 4:46

GoogleCodeExporter commented 9 years ago
Getting same issue ... can anyone please help to resolve

Original comment by dwivedih...@gmail.com on 9 May 2012 at 7:16

GoogleCodeExporter commented 9 years ago
Not sure what I did, I reinstalled, using the svn checkout, it was still doing 
it, I ignored it for a day or so, and now it's working fine....It doesn't make 
any sense

Original comment by rhal...@gmail.com on 9 May 2012 at 7:31

GoogleCodeExporter commented 9 years ago
i am still having the same issue.
i dont know what to do.

Original comment by sk6...@gmail.com on 15 Jun 2012 at 11:11

GoogleCodeExporter commented 9 years ago
I noticed on one of the YUM install scripts that there was a DB table that was 
attempted to be added with a static address of 
`testdrive`.`whatEverThatTableNameWas` and that has been fixed, try downloading 
it and installing it again

Original comment by rhal...@gmail.com on 15 Jun 2012 at 5:18

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
change from 
$friends = $inviter->getFriends(true);
to
$friends = YumUser::model()->getFriends(true);

at line 150 of modules/friendship/controllers/YumFriendshipController.php

and then you'll get following error

CDbCommand failed to execute the SQL statement: SQLSTATE[42S22]: Column not 
found: 1054 Unknown column 'demo' in 'where clause'. The SQL statement executed 
was: SELECT * FROM `message` `t` WHERE to_user_id = demo and message_read = 0 
ORDER BY timestamp DESC LIMIT 10

change from
{$id}
to
 '{$id}'
 line 193 at modules/message/models/YumMessage.php

Original comment by KO0Th...@googlemail.com on 25 Oct 2012 at 6:08