This commit is contained in:
dignajar 2016-12-01 20:51:44 -03:00
parent 3c2ddf7804
commit 9f77cefd67

View File

@ -104,9 +104,7 @@ class pluginAPI extends Plugin {
if( empty($inputs) ) {
// Default variables for $input
$inputs = array(
'token'=>''
);
$inputs = array();
}
else {
// Sanitize inputs
@ -140,6 +138,10 @@ class pluginAPI extends Plugin {
// Check authentication
if( $this->getDbField('authentication')==1 ) {
if( empty($inputs['token']) ) {
return false;
}
if( $inputs['token']!=$this->getDbField('token') ) {
return false;
}