fix: Fixed invalid lookup for adding object references

pull/2489/head
iglocska 2017-08-22 10:59:39 +02:00
parent 961bc76393
commit 412b2bcfb1
1 changed files with 1 additions and 1 deletions

View File

@ -93,7 +93,7 @@ class ObjectReferencesController extends AppController {
if ($this->_isRest()) {
$object = $this->ObjectReference->find("first", array(
'recursive' => -1,
'conditions' => array('ObjectReference' => $this->ObjectReference->id)
'conditions' => array('ObjectReference.id' => $this->ObjectReference->id)
));
return $this->RestResponse->viewData($object, $this->response->type());
} else if ($this->request->is('ajax')) {