This commit is contained in:
Paminger
2016-04-11 14:20:33 +02:00
parent d952087979
commit df889c235b
2 changed files with 6 additions and 4 deletions
+3 -2
View File
@@ -126,7 +126,8 @@ $config['rest_auth'] = 'basic';
| Note: If 'rest_auth' is set to 'session' then change 'auth_source' to the name of the session variable
|
*/
$config['auth_source'] = 'RestAPISession';
//$config['auth_source'] = 'RestAPISession';
$config['auth_source'] = 'library';
/*
|--------------------------------------------------------------------------
@@ -301,7 +302,7 @@ $config['rest_keys_table'] = 'ci_apikey';
| ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
*/
$config['rest_enable_keys'] = FALSE;
$config['rest_enable_keys'] = TRUE;
/*
|--------------------------------------------------------------------------
+3 -2
View File
@@ -10,6 +10,7 @@
* @link http://whisperocity.com/
* @since Version 1.0
* @filesource
* @example curl -H "FHC-API-Key: testapikey@fhcomplete.org" http://localhost/fhcomplete/index.ci.php/api/v1/APIAuth/login?code=aladsfasdf
*/
// ------------------------------------------------------------------------
@@ -23,7 +24,7 @@ if (! defined('BASEPATH'))
/**
* Handles user authentication and registration process
*/
class AuthAPI extends APIv1_Controller
class APIAuth extends APIv1_Controller
{
/**
* Userauth-Controller constructor.
@@ -61,7 +62,7 @@ class AuthAPI extends APIv1_Controller
$username = urldecode($this->get('username'));
$password = urldecode($this->get('password'));
$account = $this->FHCAuth->auth($username, $password);
$account = $this->fhc_auth->auth($username, $password);
// perform login checks
if (!$account)