From 62d814bb57f67f204a5bd77fbf5b20eeb8a9c170 Mon Sep 17 00:00:00 2001 From: Rick Date: Thu, 16 Jul 2020 20:38:51 +0200 Subject: [PATCH] =?UTF-8?q?Ajout=20documentation=20&=20v=C3=A9rification?= =?UTF-8?q?=20compte=20publique=20close=20#2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- getAchievements.php | 41 +++++++++++++++++++++++++++++++++++------ 1 file changed, 35 insertions(+), 6 deletions(-) diff --git a/getAchievements.php b/getAchievements.php index a2815be..cadcd26 100644 --- a/getAchievements.php +++ b/getAchievements.php @@ -1,4 +1,13 @@ 'User not found.', 'response' => $http_response_header); + } elseif (empty($listGames["response"])) { + $ret = array('error' => 'Private Account.', 'response' => $http_response_header); } else { $url = "http://api.steampowered.com/ISteamUser/GetPlayerSummaries/v0002/?key=".API_KEY."&steamids=".$steamid; $userInformations = getJson($url); @@ -117,9 +149,6 @@ if (isset($_POST['steamid'])) { } } } - //$fileJson = fopen('result.json', 'w'); - //fwrite($fileJson, json_encode($ret)); - //fclose($fileJson); $retJson = json_encode($ret); $_POST["game"] = $retJson; header('Content-Type: application/json');