name = $data['name']; $module->description = $data['description']; $module->folderName = $folderName; $module->version = $data['version']; return $module; } /** * Get a path for a file within this module. */ public function path($path = ''): string { $component = trim($path, '/'); return theme_path("modules/{$this->folderName}/{$component}"); } }