summaryrefslogtreecommitdiff
path: root/src/application/actions/profilepicture/get.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/application/actions/profilepicture/get.php')
-rw-r--r--src/application/actions/profilepicture/get.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/application/actions/profilepicture/get.php b/src/application/actions/profilepicture/get.php
index abf9135..94f474a 100644
--- a/src/application/actions/profilepicture/get.php
+++ b/src/application/actions/profilepicture/get.php
@@ -2,7 +2,11 @@
use mystic\forum\orm\User;
-$userId = $_GET["user"] ?? throw new Exception(__("Missing user id"));
+$userId = $_GET["user"] ?? call_user_func(function() {
+ http_response_code(400);
+ msg_error(__("Missing user id"));
+ exit;
+});
$user = new User();
$user->id = $userId;
if (!$db->fetch($user)) {