summaryrefslogtreecommitdiff
path: root/public/emotes/upload.php
diff options
context:
space:
mode:
Diffstat (limited to 'public/emotes/upload.php')
-rw-r--r--public/emotes/upload.php28
1 files changed, 15 insertions, 13 deletions
diff --git a/public/emotes/upload.php b/public/emotes/upload.php
index 42e58c6..96544fd 100644
--- a/public/emotes/upload.php
+++ b/public/emotes/upload.php
@@ -389,19 +389,21 @@ if ($is_manual) {
}
}
-$db->prepare("INSERT INTO actions(user_id, action_type, action_payload) VALUES (?, ?, ?)")
- ->execute([
- $uploaded_by,
- "EMOTE_CREATE",
- json_encode([
- "emote" => [
- "id" => $id,
- "code" => $code,
- "visibility" => $visibility,
- "uploaded_by" => $uploaded_by,
- ]
- ])
- ]);
+if (ACCOUNT_LOG_ACTIONS) {
+ $db->prepare("INSERT INTO actions(user_id, action_type, action_payload) VALUES (?, ?, ?)")
+ ->execute([
+ $uploaded_by,
+ "EMOTE_CREATE",
+ json_encode([
+ "emote" => [
+ "id" => $id,
+ "code" => $code,
+ "visibility" => $visibility,
+ "uploaded_by" => $uploaded_by,
+ ]
+ ])
+ ]);
+}
$db = null;