mirror of
https://github.com/aunefyren/wrapperr
synced 2024-12-14 21:22:29 +00:00
c24c3156f5
- Changed API response - Fixed bug where no shows created error message when retrieving show buddy - Tweaked username retrieved from Tautulli - Moved stat modules to function - All timecodes are converted to strings dynamically
17 lines
No EOL
615 B
PHP
17 lines
No EOL
615 B
PHP
<?php
|
|
$data = json_decode(file_get_contents("php://input"));
|
|
$config = json_decode(file_get_contents("../config/config.json"));
|
|
|
|
if (empty($config)) {
|
|
echo json_encode(array("message" => "Plex Wrapped is not configured.", "error" => true));
|
|
exit(0);
|
|
}
|
|
|
|
$functions = array("get_user_movie_stats" => $config->get_user_movie_stats,
|
|
"get_user_show_stats" => $config->get_user_show_stats,
|
|
"get_user_show_buddy" => $config->get_user_show_buddy,
|
|
"get_year_stats" => $config->get_year_stats
|
|
);
|
|
echo json_encode($functions);
|
|
exit(0);
|
|
?>
|