function _user_resource_delete in Services 6.3
Same name and namespace in other branches
- 7.3 resources/user_resource.inc \_user_resource_delete()
Delete a user.
Parameters
$uid: UID of the user to be deleted.
See also
1 string reference to '_user_resource_delete'
- _user_resource_definition in resources/
user_resource.inc - @file This file will define the resources for dealing with the user object
File
- resources/
user_resource.inc, line 348 - This file will define the resources for dealing with the user object
Code
function _user_resource_delete($uid) {
$account = user_load($uid);
if (empty($account)) {
return services_error(t('There is no user with such ID.'), 404);
}
user_delete($account, $uid);
// Everything went right.
return TRUE;
}