You are here

function tfa_accept_code in Two-factor Authentication (TFA) 7

Same name and namespace in other branches
  1. 6 tfa.module \tfa_accept_code()

Mark a code as accepted.

Parameters

int $uid UID of account.:

1 call to tfa_accept_code()
tfa_code_form_submit in ./tfa.pages.inc
Submit handler for TFA login form.

File

./tfa.module, line 287
Two-factor authentication for Drupal.

Code

function tfa_accept_code($uid) {
  db_update('tfa')
    ->fields(array(
    'accepted' => 1,
  ))
    ->condition('uid', $uid)
    ->execute();
}