mirror of
https://codeberg.org/vlw/stadia-avatar.git
synced 2025-09-13 23:23:40 +02:00
Separated client- and server-side features into seperate root folders. Since Stadia Avatar now has two versions (Userscript and Chrome extension). Added core extension functionality. Created a page constructor for extension popup. High probability that I will create a seperate repo for this feature, as it's pretty neat and very useful for future extensions.
15 lines
No EOL
350 B
PHP
15 lines
No EOL
350 B
PHP
<?php
|
|
|
|
require "../classes/Message.php";
|
|
require "../classes/Database.php";
|
|
|
|
$user_id = $_GET["userID"] ?? error("400","No userID provided");
|
|
|
|
$db = new StadiaAvatarDB();
|
|
$avatar = $db->get_avatar($user_id);
|
|
|
|
if(!$avatar) {
|
|
error("200","No avatar was found for the supplied userID");
|
|
}
|
|
|
|
echo "{\"status\":\"OK\",\"avatar\":\"${avatar}\"}"; |