aboutsummaryrefslogtreecommitdiff
path: root/model/Upcoming.php
diff options
context:
space:
mode:
authorMaZderMind2015-04-06 15:03:38 +0200
committerMaZderMind2015-04-06 15:03:38 +0200
commitfd374f8b627bde637112cd90aee92e5c84301bbf (patch)
treec6b95970abaf8baadf3a5472cc1a8b7ee128da21 /model/Upcoming.php
parentc7c528ba8787acbdc4ba84d71cf6c4e502e57e68 (diff)
Show all upcoming Events in closed View
Diffstat (limited to 'model/Upcoming.php')
-rw-r--r--model/Upcoming.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/model/Upcoming.php b/model/Upcoming.php
index 6f54814..1724d0f 100644
--- a/model/Upcoming.php
+++ b/model/Upcoming.php
@@ -2,14 +2,13 @@
class Upcoming
{
- public function getNextEvent()
+ public function getNextEvents()
{
try {
$events = file_get_contents('https://c3voc.de/eventkalender/events.json?filter=upcoming');
$events = json_decode($events, true);
- $names = array_keys($events['voc_events']);
- return $events['voc_events'][$names[0]];
+ return array_values($events['voc_events']);
}
catch(ErrorException $e)
{