load_listings(); return \KdxDirectoryWidget::render($listings, 'scn01'); } private function load_listings() { $config = $this->load_config(); $path = $config['listings_file'] ?? 'addon/scn01/listings.json'; $raw = @file_get_contents($path); if ($raw === false) return ['core' => [], 'tier1' => [], 'tier2' => [], 'other' => []]; $data = json_decode($raw, true); return (json_last_error() === JSON_ERROR_NONE) ? $data : ['core' => [], 'tier1' => [], 'tier2' => [], 'other' => []]; } private function load_config() { $raw = @file_get_contents('addon/scn01/config.json'); if ($raw === false) return []; $data = json_decode($raw, true); return (json_last_error() === JSON_ERROR_NONE) ? $data : []; } }