From: Daniel Karbach Date: Fri, 19 Jun 2026 13:25:15 +0000 (+0200) Subject: remove player names from TFL episode title X-Git-Url: https://git.localhorst.tv/?a=commitdiff_plain;h=0284f690b0cfdd0f3c03e1bd6cffb07067e341d3;p=alttp.git remove player names from TFL episode title --- diff --git a/app/Console/Commands/SyncTFL.php b/app/Console/Commands/SyncTFL.php index 5569b8c..c294740 100644 --- a/app/Console/Commands/SyncTFL.php +++ b/app/Console/Commands/SyncTFL.php @@ -102,10 +102,11 @@ class SyncTFL extends Command { $episode->confirmed = true; $episode->save(); - if (!preg_match('/\\| ([^|]+) vs\\. ([^|]+) \\|/', $tflEntry['name'], $matches)) { + if (!preg_match('/^(.*) \\| ([^|]+) vs\\. ([^|]+) \\| (.*)$/', $tflEntry['name'], $matches)) { return; } - $tflPlayers = [$matches[1], $matches[2]]; + $episode->title = $matches[1].' - '.$matches[4]; + $tflPlayers = [$matches[2], $matches[3]]; $this->purgePlayers($episode, $tflPlayers); foreach ($tflPlayers as $tflPlayer) {