Fix model form-binding with array with objects and object with arrays.

This commit is contained in:
Gary committed 2015-04-25 13:14:08 +01:00
1 parent 55eb889aca
commit e4b32919a3
2 files changed
+13 -8

No files matched your search

+1 -8
View File
@@ -935,14 +935,7 @@ class FormBuilder {
*/
protected function getModelValueAttribute($name)
{
if (is_object($this->model))
{
return object_get($this->model, $this->transformKey($name));
}
elseif (is_array($this->model))
{
return array_get($this->model, $this->transformKey($name));
}
return data_get($this->model, $this->transformKey($name));
}
/**