diff --git a/src/helpers/SaveForm.php b/src/helpers/SaveForm.php index f9240f21..de1b2b89 100644 --- a/src/helpers/SaveForm.php +++ b/src/helpers/SaveForm.php @@ -58,7 +58,11 @@ public static function loadSavedForms($generatorName) if (method_exists($module, 'getBasePath')) { $basePath = $module->getBasePath(); } else { - $reflector = new \ReflectionClass($module['class']); + if (is_array($module)) { + $reflector = new \ReflectionClass($module['class']; + } else { + $reflector = new \ReflectionClass($module); + } $basePath = StringHelper::dirname($reflector->getFileName()); } $basePath .= '/gii';