You are here

function nodejs_subscribe_delete in Node.js integration 6

Same name and namespace in other branches
  1. 7 nodejs_subscribe/nodejs_subscribe.module \nodejs_subscribe_delete()

Delete a subscription to a node.

Parameters

mixed $node:

mixed $uid:

Return value

boolean

1 call to nodejs_subscribe_delete()
nodejs_subscribe_unsubscribe_node in nodejs_subscribe/nodejs_subscribe.module
Page callback for unsubscribing to a node.

File

nodejs_subscribe/nodejs_subscribe.module, line 337

Code

function nodejs_subscribe_delete($node, $uid) {
  nodejs_remove_user_from_channel($uid, 'nodejs_subscribe_node_' . $node->nid);
  return db_query('DELETE FROM {nodejs_subscribe_subscription} WHERE nid = %d AND uid = %d', $node->nid, $uid);
}