Merge branch '2.4' of github.com:MISP/MISP into 2.4

pull/4644/head^2
mokaddem 2019-05-16 17:28:19 +02:00
commit 72c83a7f35
1 changed files with 16 additions and 0 deletions

View File

@ -3793,6 +3793,22 @@ class Server extends AppModel
return array('status' => 6);
}
}
$this->Log = ClassRegistry::init('Log');
$this->Log->create();
$this->Log->save(array(
'org' => 'SYSTEM',
'model' => 'Server',
'model_id' => $id,
'email' => 'SYSTEM',
'action' => 'error',
'user_id' => 0,
'title' => 'Error: Connection test failed. Returned data is in the change field.',
'change' => sprintf(
'response () => (%s), response-code () => (%s)',
$response->body,
$response->code
)
));
return array('status' => 3);
}
}