<?php
include '../config/index.php';
include '../module/index.php';
 
$data = new Database;

$con = $data->connect();

$user = new User($con);

$post = filter_var_array($_POST,FILTER_SANITIZE_FULL_SPECIAL_CHARS);

$cot    = $post['auth'];

if($user->getUserNameById($_SESSION['id'] )->auth == $cot){
   echo $data->redirect('../account/../index?vat=vat');
}else{
   $_SESSION['t_error_c']  = 'Incorrect Auth CODE';
   echo $data->redirect('../account/../index?auth=auth');
}


?>