mirror of https://github.com/MISP/MISP
Update DecayingModelController.php
Found a bug importing DecayingModels to a new instance that hinders the Decaying Model Mapping with attribute typespull/8973/head
parent
ce0c79f7f7
commit
1b6ce3bf4b
|
@ -55,9 +55,9 @@ class DecayingModelController extends AppController
|
|||
$json['org_id'] = $this->Auth->user()['org_id'];
|
||||
|
||||
$attribute_types = array();
|
||||
if (!empty($json['attribute_types'])) {
|
||||
$attribute_types = $json['attribute_types'];
|
||||
unset($json['attribute_types']);
|
||||
if (!empty($json['DecayingModel']['attribute_types'])) {
|
||||
$attribute_types = $json['DecayingModel']['attribute_types'];
|
||||
unset($json['DecayingModel']['attribute_types']);
|
||||
}
|
||||
|
||||
if ($this->DecayingModel->save($json)) {
|
||||
|
|
Loading…
Reference in New Issue