summaryrefslogtreecommitdiff
path: root/includes/jobs/PKMembers.php
diff options
context:
space:
mode:
authorRaindropsSys <contact@minteck.org>2023-04-02 23:03:02 +0200
committerRaindropsSys <contact@minteck.org>2023-04-02 23:03:02 +0200
commit02eda3e4c9b4ba718f1fff70b7328ed8cdd5e63b (patch)
tree6d1dec61008998aadc6b69f7e750712794d99324 /includes/jobs/PKMembers.php
parentf559308a1b42a9036135d764374a8c007b7d70a9 (diff)
downloadpluralconnect-02eda3e4c9b4ba718f1fff70b7328ed8cdd5e63b.tar.gz
pluralconnect-02eda3e4c9b4ba718f1fff70b7328ed8cdd5e63b.tar.bz2
pluralconnect-02eda3e4c9b4ba718f1fff70b7328ed8cdd5e63b.zip
Updated 35 files, added 11 files and deleted includes/components/search.inc (automated)
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