Skip to content

Commit 710ec7c

Browse files
committed
Add option to only return SteamIDs to GetFriendList
1 parent 35615ce commit 710ec7c

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/Syntax/SteamApi/Steam/User.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ public function GetPlayerBans($steamId = null)
126126
return $client->players;
127127
}
128128

129-
public function GetFriendList($relationship = 'all')
129+
public function GetFriendList($relationship = 'all', $summaries = true)
130130
{
131131
// Set up the api details
132132
$this->method = __FUNCTION__;
@@ -152,7 +152,11 @@ public function GetFriendList($relationship = 'all')
152152
$steamIds[] = $friend->steamid;
153153
}
154154

155-
$friends = $this->GetPlayerSummaries(implode(',', $steamIds));
155+
if($summaries) {
156+
$friends = $this->GetPlayerSummaries(implode(',', $steamIds));
157+
} else {
158+
$friends = $steamIds;
159+
}
156160

157161
return $friends;
158162
}

0 commit comments

Comments
 (0)