private function syncEvent(Event $event) {
$sgHandle = substr($event->external_schedule, 3);
$from = now()->sub(1, 'day');
- $to = now()->add(6, 'day');
+ $to = now()->add(14, 'day');
$sgSchedule = HTTP::get('https://speedgaming.org/api/schedule/', [
'event' => $sgHandle,
'from' => $from->toIso8601String(),
$episode->event()->associate($event);
$episode->title = $sgEntry['match1']['title'];
$start = Carbon::createFromFormat('Y-m-d\TH:i:sP', $sgEntry['when']);
- if ($start->ne($episode->start)) {
+ if (!$episode->start || $start->ne($episode->start)) {
$episode->start = $start;
}
$episode->estimate = $sgEntry['length'] * 60;