|
Re: fud_delete_user() produces SQL error? |
Wed, 17 January 2007 14:29 |
|
Correct me if you made changes other than this:
http://cvs.prohost.org/c/index.cgi/FUDforum/chngview?cn=11723
The above fix doesn't quite do it. _fud_simple_fetch_query returns type Object, which the else wraps in an array, and then your fix takes the array back off and passes in the object, which usr_delete still chokes on.
It does work if you change your current code to:
foreach ($data as $v) {
usr_delete($v->id);
}
But you may not want to get an Object back in the first place?
|
|
|
fud_delete_user() produces SQL error? |
Mon, 15 January 2007 15:29 |
|
Does fud_delete_user() in fudapi.inc.php work for other people?
When I call it, I get the following SQL error:
FUDforum2misc/include/theme/default/db.inc:72
FUDforum2misc/include/users_adm.inc:25
FUDforum2misc/scripts/fudapi.inc.php:949
FUDforum2misc/FUDtester.php:73
) 1054: Unknown column 'Object' in 'where clause'
Query: DELETE FROM fud26_mod WHERE user_id IN(Object)
I've tried passing both array(5) and just 5 into fud_delete_user(), makes no difference, problem seems internal.
Looks like fud_delete_user() uses _fud_simple_fetch_query(), which uses db_rowobj() which is returning an object instead of an array as expected by the rest of the code?
Zanks,
/Maarten.
|
|