Example #1
0
 /**
  * Simple function that allows us to get an array of configurations
  * @param Event $event
  * @return Config[]
  */
 public static function getConfigsForEvent($event)
 {
     $path = $event->getClient()->getPath() . "/events/{$event->getEventCode()}/configs.json";
     $json = $event->client->requestJson('GET', $path);
     $configs = array();
     foreach ($json as $config) {
         $config = new Config($event->getClient(), $config, $event);
         $configs[$config->getConfigKey()] = $config;
     }
     return $configs;
 }