mirror of https://github.com/MISP/MISP
fix: flatten the events for the restSearch API's lookup functions
- otherwise valid events that only contain objects get blockedpull/2509/head
parent
a61b5007cf
commit
9e71fbb5f7
|
@ -1816,7 +1816,8 @@ class AttributesController extends AppController {
|
|||
'fields' => array('Attribute.*', 'Event.org_id', 'Event.distribution'),
|
||||
'withAttachments' => $withAttachments,
|
||||
'enforceWarninglist' => $enforceWarninglist,
|
||||
'includeAllTags' => true
|
||||
'includeAllTags' => true,
|
||||
'flatten' => 1
|
||||
);
|
||||
if ($deleted) {
|
||||
$params['deleted'] = 1;
|
||||
|
|
|
@ -2684,7 +2684,8 @@ class EventsController extends AppController {
|
|||
'contain' => array(),
|
||||
'recursive' => -1,
|
||||
'list' => true,
|
||||
'event_ids' => true
|
||||
'event_ids' => true,
|
||||
'flatten' => 1
|
||||
);
|
||||
$attributes = $this->Event->Attribute->fetchAttributes($this->Auth->user(), $params);
|
||||
$eventIds = array();
|
||||
|
|
Loading…
Reference in New Issue