function comment_notify_update_notification in Comment Notify 8
Same name and namespace in other branches
- 7 comment_notify.inc \comment_notify_update_notification()
Updated a notification with a different notification type.
Parameters
int $cid: The comment id.
int $notify: The value that is going to be updated.
Return value
bool TRUE if the notification was updated correctly.
1 call to comment_notify_update_notification()
- _comment_notify_submit_comment_form in ./comment_notify.module 
- Additional submit handler for the comment form.
File
- ./comment_notify.inc, line 84 
- Contains functions which utilize the database and other internal helpers.
Code
function comment_notify_update_notification($cid, $notify) {
  return (bool) \Drupal::database()
    ->update('comment_notify')
    ->fields([
    'notify' => $notify === NULL ? 0 : $notify,
  ])
    ->condition('cid', $cid)
    ->execute();
}