Browse Source

Minor webfinger tweak.

default 3 months ago
parent
commit
bde5748a6e
1 changed files with 5 additions and 1 deletions
  1. 5 1
      webfinger.c

+ 5 - 1
webfinger.c

@@ -82,7 +82,11 @@ int webfinger_request_signed(snac *snac, const char *qs, xs_str **actor, xs_str
 
     if (obj == NULL && valid_status(status) && payload) {
         obj = xs_json_loads(payload);
-        object_add(cached_qs, obj);
+
+        if (obj)
+            object_add(cached_qs, obj);
+        else
+            status = HTTP_STATUS_BAD_REQUEST;
     }
 
     if (obj) {