mirror of https://github.com/MISP/MISP
fix: [attackMatrix] do not throw an error for an edge case where the
user did not have full permissionpull/4024/head
parent
4edc93f325
commit
8708d5133c
|
@ -4590,8 +4590,9 @@ class EventsController extends AppController
|
|||
if ($scope == 'event') {
|
||||
$eventId = $scope_id;
|
||||
} elseif ($scope == 'attribute') {
|
||||
$attribute = $this->Event->Attribute->fetchAttributesSimple($this->Auth->user(), array(
|
||||
'conditions' => array('Attribute.id' => $scope_id)
|
||||
$attribute = $this->Event->Attribute->fetchAttributes($this->Auth->user(), array(
|
||||
'conditions' => array('Attribute.id' => $scope_id),
|
||||
'fields' => array('event_id')
|
||||
));
|
||||
if (empty($attribute)) {
|
||||
throw new Exception("Invalid Attribute.");
|
||||
|
|
Loading…
Reference in New Issue