summaryrefslogtreecommitdiff
path: root/includes/jobs/PKMembers.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/jobs/PKMembers.php')
-rw-r--r--includes/jobs/PKMembers.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/includes/jobs/PKMembers.php b/includes/jobs/PKMembers.php
index 529a820..536853d 100644
--- a/includes/jobs/PKMembers.php
+++ b/includes/jobs/PKMembers.php
@@ -30,6 +30,8 @@ if (trim($data) !== "" && $data !== false) {
$parsed = json_decode($data, true);
foreach ($parsed as $index => $member) {
+ echo(($member["display_name"] ?? $member["name"]) . "\n");
+
if (isset($member["avatar_url"])) {
$dominantColor = substr(ColorThief::getColor($member["avatar_url"], outputFormat: "hex"), 1);
} else {
@@ -44,5 +46,8 @@ if (trim($data) !== "" && $data !== false) {
}
$data = json_encode($parsed, JSON_PRETTY_PRINT);
- file_put_contents("./data/$system/members.json", $data);
-} \ No newline at end of file
+ file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/$system/members.json", $data);
+}
+
+file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/navigation.json", "{}");
+file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/home.json", "{}"); \ No newline at end of file