* Fixes an issue where any api_key would be validated * Now returns user ID upon success, aborts script processing with error on fail
13 lines
243 B
PHP
13 lines
243 B
PHP
<?php
|
|
|
|
// Make sure we are called from index.php
|
|
if (!defined('SECURITY'))
|
|
die('Hacking attempt');
|
|
|
|
// Check for valid API key
|
|
$id = $user->checkApiKey($_REQUEST['api_key']);
|
|
|
|
header('HTTP/1.1 400 Bad Request');
|
|
die('400 Bad Request');
|
|
?>
|