From 49a75b623969c8cef694f0442521a4afa54482d4 Mon Sep 17 00:00:00 2001 From: nyeholt Date: Fri, 22 Nov 2013 15:00:08 +1100 Subject: [PATCH] FIX Fixed issue where items were created without being run through DI --- code/GridFieldAddNewInlineButton.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/GridFieldAddNewInlineButton.php b/code/GridFieldAddNewInlineButton.php index 9bd52095..f168f17e 100755 --- a/code/GridFieldAddNewInlineButton.php +++ b/code/GridFieldAddNewInlineButton.php @@ -137,7 +137,7 @@ public function handleSave(GridField $grid, DataObjectInterface $record) { } foreach($value[__CLASS__] as $fields) { - $item = new $class(); + $item = $class::create(); $extra = array(); if($list instanceof ManyManyList) {