You are here

function nodejs_kick_user in Node.js integration 6

Same name and namespace in other branches
  1. 8 nodejs.module \nodejs_kick_user()
  2. 7 nodejs.module \nodejs_kick_user()

Kick a user off the node.js server.

Parameters

mixed $uid:

1 string reference to 'nodejs_kick_user'
nodejs_drush_command in ./nodejs.drush.inc
Implements hook_drush_command().

File

./nodejs.module, line 51

Code

function nodejs_kick_user($uid) {
  $response = Nodejs::kickUser($uid);
  if (isset($response->error)) {
    watchdog('nodejs', t('Error kicking uid "%uid" from the Node.js server: [%code] %error', array(
      '%uid' => $uid,
      '%code' => $response->code,
      '%error' => $response->error,
    )));
    return FALSE;
  }
  else {
    return $response;
  }
}