From 42d4ea396121355db7a2043c3c9ffb113497ef65 Mon Sep 17 00:00:00 2001 From: Thijs Stobbelaar Date: Wed, 22 Nov 2023 16:09:38 +0100 Subject: [PATCH] update --- latestmatches.php | 12 ++++++------ update/get_matches.ps1 | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/latestmatches.php b/latestmatches.php index de2b080..6b14763 100644 --- a/latestmatches.php +++ b/latestmatches.php @@ -61,16 +61,16 @@ $ogDescription = "Dive into the detailed match stats of DTCH Clan in PUBG. Explo echo ""; echo ""; foreach ($players_matches as $match) { - print_r($match['stats']); + // print_r($match['stats']); foreach ($match['stats'] as $stats) { if ($stats['name'] === $selected_player) { - // if (isset($_GET['filter_by_match_type'])) { - // if ($_GET['filter_by_match_type'] !== 'all' && $match['matchType'] !== $_GET['filter_by_match_type']) { - // continue; - // } - // } + if (isset($_GET['filter_by_match_type'])) { + if ($_GET['filter_by_match_type'] !== 'all' && $match['matchType'] !== $_GET['filter_by_match_type']) { + continue; + } + } $date = new DateTime($match['createdAt']); $date->modify('+1 hours'); $formattedDate = $date->format('m-d H:i:s'); diff --git a/update/get_matches.ps1 b/update/get_matches.ps1 index 5430119..8b81b89 100644 --- a/update/get_matches.ps1 +++ b/update/get_matches.ps1 @@ -114,7 +114,7 @@ foreach ($file in $matchfiles) { createdAt = $filecontent.data.attributes.createdAt mapName = $filecontent.data.attributes.mapName id = $filecontent.data.id - stats = $player_matches_cached + stats = @($player_matches_cached) } } write-output "NEW $matchfiledate"
Match DateGame ModeMatch TypeMapKillsDamage DealtTime Survivedwin Place